• Post Reply Bookmark Topic Watch Topic
  • New Topic

pop up window using java script in JSP  RSS feed

 
Harish Maridi
Ranch Hand
Posts: 60
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I am generating a popup window from the JSP using javascript.
My question is are we able to send data from originating JSP to pop up JSP through javascript.
I need to use a parameter from the originating jsp in popup jsp.
I am using struts framework.
If we can send data, please let me know way of do it.
I am also providing code through which I am generating the popup window.
I am alltaching the following function to a button click event.
 
Harish Maridi
Ranch Hand
Posts: 60
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks in advacne
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 65833
134
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Remember that the JSP for the parent window runs on the server in order to create the HTML page to send to the client. Once at the client, and the JavaScript code gets a chance to run, there's no "JSP-ness" there, so no, you can't directly use JSP data.

But... in your parent JSP you can create any JavaScript code necessary, so it should be easy to generate a URL for your child window that contains the data you need as part of the query string.
 
Harish Maridi
Ranch Hand
Posts: 60
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks, I got it.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!