Click to See Complete Forum and Search --> : Set location of child window from parent


cezza30
02-24-2003, 04:39 PM
HI!!!

I've opened a window using the following code:

window.open("NewBrowser.html","newwin",config='status=0,toolbar=0,resizable=0');

and I want to be able to set the location of this new window via the user typing an address into a text box in the parent window.

How do I set the location of the new window, ie instead of writing 'location.href=document.formname.textboxname.value' what do I put?

Thanks for any help in advance . . . .

AdamBrill
02-24-2003, 04:47 PM
If you call the window like this:

win = window.open("NewBrowser.html","newwin",config='status=0,toolbar=0,resizable=0');

Then you would change the location like this:

win.location = "www.wherever.com";

I hope that helps. ;)