Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Controlling the browser window

Status
Not open for further replies.

bdavis96

Programmer
Feb 11, 2002
97
US
I have a webpage opening up in a new window when a user clicks the link. I want the browser back button on the new window to disable (so they can't click back, only close window) or override the browser back button to close the window. Any help would be much appreciated.

 
You can turn off (hide) the toolbars on a window, but this is evil and shouldn't really be done (in the name of usability).
 
I want the browser back button on the new window to disable (so they can't click back, only close window)"

That's what happens anyway when you open a link in a new window - it's one of the main reasons why doing so is generally such a bad idea: it breaks the back button. See .

-- Chris Hunt
 
Even if you hide the toolbar as mentioned above, the user can still right-click on your page and select the "Back" option from there (unless you also disable right-clicking).

Why are you so determined that the user can't go back to the previous page?
 
The web isn't about sending a user down "path A" or "path B".
It is more about not only letting them choose whatever route they like, but also allow them to use any mode of transport to go wherever they like. Not only that, but they can choose to wear whatever they like and travel whenever they choose.

I just made that up, it needs work, but I like it.
 
If a new web page opens (presumably from a link), then the back button would be useless anyway since there is no history for that page.

There's always a better way. The fun is trying to find it!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top