File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JSP and the fly likes Javascript => JSP Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSP
Bookmark "Javascript => JSP" Watch "Javascript => JSP" New topic
Author

Javascript => JSP

Joey Alencar
Ranch Hand

Joined: Jun 26, 2001
Posts: 43
I'd like to know if there's a way to get the value of a javascript variable and set this value to a JSP variable.
Thanks.
William Brogden
Author and all-around good cowpoke
Rancher

Joined: Mar 22, 2000
Posts: 12823
    
    5
Keep in mind that Javascript executes on the browser while JSP works on the server. Therefore any information transfer from Javascript to JSP will have to be as part of a browser request - either a GET or a POST.
You could have Javascript set a hidden variable in a <FORM> for instance.
Bill
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Javascript => JSP