This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes JSP and the fly likes opening popup window conditionally Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "opening popup window conditionally " Watch "opening popup window conditionally " New topic
Author

opening popup window conditionally

Vaithiya Sundaram
Ranch Hand

Joined: Apr 22, 2004
Posts: 98
From a JSP called "ABC.jsp", when I click "View Item" button it should call
corresponding action class,process and display results(displayitems.jsp) in a popup window. for some reason if the result is error page or login page then the popup window should not be opened rather it should replace ABC.jsp in main window.

i.e.
If result is displayitems.jsp I want to open this jsp in pop up window and
keep ABC.jsp open in main window.
If result is some other page I want to replace ABC.jsp with result page in
main window.

how to do this opening the popup window conditionally i.e. based on result
page?

Your response is appreciated!
Thanks


Vaithiyanathan Sundaram<br />SCJP, SCBCD, SCEA part1
Bosun Bello
Ranch Hand

Joined: Nov 06, 2000
Posts: 1510
I guess you can set a flag when an error occurs, and then check for that flag in the JSP (using hidden fome field)


Bosun (SCJP, SCWCD)
So much trouble in the world -- Bob Marley
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: opening popup window conditionally
 
Similar Threads
Focus to Popup window
Open new window
opening popup window conditionally
"Please wait ...." message to be displayed
opening popup window conditionally