|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
I have the following situation:
a parent window open a child window (with "window.open(etc...)") and at the same time navigate itself at a new URL1. at the time of closing the child window I want to navigate the parent window to URL2. I treat event "onunload" of the child window, but the object "window.opener" does not exist anymore after the parent navigate to URL1. is any posibility to manage this situation?? Please HELP!!! |
|
#2
|
|||
|
|||
|
When you open the child window, use an expression like:
win1 = window.open(.....) At some point within the parent, use an if...then statement to check for existance of the child. For example, using a javascript URL in the <body> tag, try: <body onfocus="javascript win1)?( window.location=URL);">In the above case, anytime the parent regains focus, it checks for existance of win1. If it does exist, the script does nothing ( . Sometimes I just put in a dummy expression like x=1. If it doesn't exist, it loads URL.<BLOCKQUOTE><font size="1" face="Verdana,Arial,Helvetica">quote:</font><HR>Originally posted by Dr@aMcula: I have the following situation: a parent window open a child window (with "window.open(etc...)") and at the same time navigate itself at a new URL1. at the time of closing the child window I want to navigate the parent window to URL2. I treat event "onunload" of the child window, but the object "window.opener" does not exist anymore after the parent navigate to URL1. is any posibility to manage this situation?? Please HELP!!![/quote] |
|
#3
|
|||
|
|||
|
I apologize for the smiley faces. Forgot to disable the damn things. Here is my post again hopefully without the smiley faces.
When you open the child window, use an expression like: win1 = window.open(.....) At some point within the parent, use an if...then statement to check for existance of the child. For example, using a javascript URL in the <body> tag, try: <body onfocus="javascript win1)?( window.location=URL);"> In the above case, anytime the parent regains focus, it checks for existance of win1. If it does exist, the script does nothing (Sometimes I just put in a dummy expression like x=1. If it doesn't exist, it loads URL. |
|
#4
|
|||
|
|||
|
Hi,
Thanks a lot for your help!! I am now edified about the situation and my problem is solved. Thanks again! |
![]() |
| Viewing: Dev Shed Forums > Web Design > HTML Programming > Handling windows history |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|