Re: Header() to a different browser instance

From: Date: Sat, 08 Jul 2000 14:47:40 +0000
Subject: Re: Header() to a different browser instance
References: 1 2  Groups: php.general 
Request: Send a blank email to php-general+get-5546@lists.php.net to get a copy of this message
Erik Stainsby wrote: > > Eric, > > You will not be able to redirect programmatic flow from a > child window back to the parent window. You can spawn a > child because the parent "knows how to" - there is no > mechanism in the protocols that I've ever come accross > which would allow the child to return control to a parent > browser. I guess I might be confused but doesnt the TARGET entity in the html protocol access the parent window from a child window. I mean if you pop a window and in that child window you have a <A HREF="URL" TARGET="parent_window_name"></A> link, when you click the link it will refresh the parent window to grab the url. So you should be able to use the document.window object in javascript to both update the parent window and close the popup. Simple javascript psudeo code would be: document.parent_window_name.location.href=new url document.child_window_name.window.close() or something close to that And then use a javascript url in the link in the child window like <A HREF=javascript:function()>CLOSE ME</A> Seems that should work. Can anyone tell me why it wouldnt work or if it does work post the code?

« previous php.general (#5546) next »