DaniWeb IT Discussion Community

DaniWeb IT Discussion Community (http://www.daniweb.com/forums/)
-   JavaScript / DHTML / AJAX (http://www.daniweb.com/forums/forum117.html)
-   -   open link in opening window (http://www.daniweb.com/forums/thread28941.html)

goldeagle2005 Jul 25th, 2005 11:20 am
open link in opening window
 
Hi all

If I create a link that opens a new window, how do i make it such that when I click a link on this page in the new window, that link should open in the original window?

I was guessing its using javascript. Any idea how?
Thanks

tgreer Jul 25th, 2005 2:52 pm
Re: open link in opening window
 
You use "self.opener.href.location = ".

So consider this link in your NEW page:

<a href="" onclick="self.opener.href.location = 'http://www.daniweb.com'";>

Which means "I'm a link to nowhere, but when you click me, set the location of the window that opened me to daniweb".


All times are GMT -4. The time now is 2:22 am.

Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC