Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

forcing users to close popups

 
AnilPrakash Raju
Ranch Hand
Posts: 137
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I would like users to close the popup window before entering data in the parent window.
How do you force users to do this?
Is there a parameter in the window.open call?

Thanks in advance
Anil
 
Niki Nono
Ranch Hand
Posts: 256
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
use a modal dialog box for achieving this.
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65225
95
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Modal dialogs are IE-only.

I achieve this in a cross-browser manner by using a floating div that emulates a dialog.
 
Marc Luzietti
Ranch Hand
Posts: 84
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Most modal scripts rely on checking the browser every second to make sure the window is on top. Not a particularly friendly thing to do. You could write a script so that onBlur the window is refocused, but there are ways around that too.

The IE modal property, in addition to being IE only, has problems passing data back to the originating window.

The best method is to either use a hidden div that becomes visible or to use an AJAX call.
[ March 01, 2006: Message edited by: Marc Luzietti ]
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic