1. Banned (not really)
    Devshed Supreme Being (6500+ posts)

    Join Date
    Dec 1999
    Caro, Michigan
    Rep Power
    I'm thinking javascript is the way to do this.

    I've got a login screen, members only area, and a function to logout. once a user logs out, it returns them to the login screen. if they left the browser like that and someone else came up to it, they could use the back button to go back to the login page where the first user filled out his login and password, then log in as the first user.

    is there a way to prevent the use of the back button or erase it's history?? is there a way to force the browser window to close?

    thanks for any help.

    ---John Holmes
  2. #2
  3. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Oct 1999
    Rep Power
    Yes. You can use the location.replace() method. For example:

    <input type="button" value="Go" onClick="window.location.replace('nextpage.html');">

    The current pages history entry will be replaced with the nextpage.html and this will also load the nextpage.html.


Similar Threads

  1. can i call the back button?
    By frankieluccini in forum HTML Programming
    Replies: 5
    Last Post: January 12th, 2004, 08:26 AM
  2. post without user hitting submit button
    By toddschw in forum PHP Development
    Replies: 2
    Last Post: July 15th, 2002, 06:10 PM
  3. Browser back button
    By mpventura in forum HTML Programming
    Replies: 4
    Last Post: October 12th, 2001, 12:15 AM
  4. Problem how to cache userinfo when he press back button..
    By roman987 in forum PHP Development
    Replies: 1
    Last Post: October 2nd, 2001, 10:44 PM
  5. back button hijacking
    By computervisions in forum Antivirus Protection
    Replies: 6
    Last Post: August 17th, 2001, 01:31 PM

IMN logo majestic logo threadwatch logo seochat tools logo