Sorry if it looks stupid question but is it possible to return the response from a JavaScript confirmbox or messagebox to a ruby program as a value?
I click on confirmbox’s “yes” button, this response is stored in a variable, and then this variable is returned to ruby?
Sure, it´s easy. Just send an XHR back to the server. If your are using jQuery you could do something like this:
An XHR request (aka AJAX) is basically the same as a normal one except that it’s performed in background (which looks like what you are looking for).