GeeCON Prague 2014*
The moose likes JSP and the fly likes JSP work with Javascript (Pain!) Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Java » JSP
Bookmark "JSP work with Javascript (Pain!)" Watch "JSP work with Javascript (Pain!)" New topic
Author

JSP work with Javascript (Pain!)

Peter Pu
Greenhorn

Joined: Apr 22, 2004
Posts: 2
as we all know, JSP is server page and Javascript is for client only.
but somehow I really need them to work together
the situation is I have a pop up window, and it will pass something back to the original window using javascript
and on the original window, I need to store that value in a bean, or a variable on JSP (java variable)
and body know how to do this?
maybe with cookie?..or?
thanks!!
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61298
    
  66

The only way to get Javascript to communicate back to the server is to post a request. Your popup can do this in a hidden frame, or to itself before closing.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Peter Pu
Greenhorn

Joined: Apr 22, 2004
Posts: 2
ok, thanks!
I will try it
 
GeeCON Prague 2014
 
subject: JSP work with Javascript (Pain!)