View Full Version : Changing a Bookmark URL

08-08-2002, 07:50 PM
Does anyone know of a way to change the URL when someone adds the page to their bookmarks/faves, to an alternative page?

The reason is I have a site which launches in a pop up window and if people bookmark that popup instead of the page containing the link to the popup, when they return the site will launch with scrollbars/resize handle etc, which I don't want it to do.

Therefore, I would like them to somehow be forced each time they visit the site to launch it from the page containing the link to the popup!

Alternatively, if this can't be done is there a way of adding some code that will remove the scrollbars/resizebox/status panel etc. from the CURRENT window? I can make the current window a certain size and position, but cant control the on/off state of the window furniture.

Any help greatly appreciated

Roy Sinclair
08-08-2002, 08:48 PM
I haven't tried this but it should be possible to have the page which calls the pop up to set a name for the window:

<body onload="self.name='caller';" onunload="self.name='';">

Then the pop up could simply check:

if (window.opener == null || window.opener.name != 'caller') document.location.href = 'insert calling page url';

08-09-2002, 01:44 PM
Thanks Roy, however I think I'm going to give up on this one as I'm not sure what I'm doing!

I'm going to try an alternative design