On May 7, 2007, at 10:36 PM, Guillaume wrote:
Thanks for your help,
but i already included that… my problem is to return the Javascript
variable in a ruby variable…
Cause Javascript is executed on Client side, so i don t see how to get
back the content of that variable later in the ruby code
You have to send it back somehow. A hidden field in a form, a
parameter in the URL, Ajax, …
You’ll typically write JavaScript code to hook into the new request
to add the value of the variable when the request starts. For
instance, if there’s a form some code in onsubmit sets the hidden
field to the value of the variable at that moment. You see the idea.
– fxn