This week's book giveaway is in the Agile forum.
We're giving away four copies of Fixing your Scrum and have Ryan Ripley & Todd Miller on-line!
See this thread for details.
Win a copy of Fixing your Scrum this week in the Agile forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Rob Spoor
  • Liutauras Vilda
Sheriffs:
  • Jeanne Boyarsky
  • Junilu Lacar
  • Tim Cooke
Saloon Keepers:
  • Tim Holloway
  • Piet Souris
  • Stephan van Hulst
  • Tim Moores
  • Carey Brown
Bartenders:
  • Frits Walraven
  • Himai Minh

Windows XP Popup blocking

 
Ranch Hand
Posts: 32
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

I have a situation where I click on a href in my first jsp, say Test1.jsp and am redirected to Test2.jsp, which in turn opens a new window using window.open from a javascript. This works fine when there is no popup blocker. Unfortunately, IE on Windows XP has popup blocker with medium severity and it blocks the new window. Here's how my code is:

Test1.jsp



NOTE: My original page has a menu item on clicking which, I will be redirected to Test2.jsp.

Test2.jsp



If you look at my code, I am calling the javascript function to open the window inside the <head> tag. I tried to put it in body onload too, but it didnot help either.

The reason I couldn't open the new window from Test1.jsp itself is, I want user to complete some test in the new window and then come back to a page that asks him to click on something to get the score. [I haven't put that refresh button code in test2.jsp, but just the skeletal code]

How do I go about opening the new window so that it is not treated as a popup?

Any help is appreciated.

Thanks
Padma

[ January 09, 2006: Message edited by: Priyaa V Kumar ]

[ January 09, 2006: Message edited by: Priyaa V Kumar ]
[ January 09, 2006: Message edited by: Bear Bibeault ]
 
author
Posts: 15385
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Doesn't you whole purpose behind this question defeat what a pop up blocker is meant to do?

The solution is to tall the people to enable pop ups on the site or have them open it up from a link with the action of onclick.

Eric
 
Ranch Hand
Posts: 413
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I would put a check there - if window did not open display a div in the middle of the page with a message about popup blocker and a link to hide this div and open a window.
[ January 09, 2006: Message edited by: Yuriy Fuksenko ]
 
Priyaa V Kumar
Ranch Hand
Posts: 32
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks for your replies, guys. I was able to overcome the problem by this approach.

In click event of test1.jsp open the new window with test2.jsp as target.
Then, in test2.jsp do the logic and then do a JSP redirect (or a javacript window.location.href) to the actual page you want to show on the new window.
 
joke time: What is brown and sticky? ... ... ... A stick! Use it to beat this tiny ad!
the value of filler advertising in 2021
https://coderanch.com/t/730886/filler-advertising
reply
    Bookmark Topic Watch Topic
  • New Topic