Disable back button

Discussion in 'ASP .Net' started by =?Utf-8?B?UGF1bA==?=, Dec 11, 2004.

  1. Hi, just wondering if there is a way to disable the back button of the
    browser as I have a logoff page and would like to not allow the back
    operation? Guessing there may be a way to do it through java script.
    --
    Paul G
    Software engineer.
     
    =?Utf-8?B?UGF1bA==?=, Dec 11, 2004
    #1
    1. Advertising

  2. You'd think there would be, but there's not.
    A common approach is to close the window, and open a new one if you must.
    This new window will have no history so the back button will be disabled.

    --
    I hope this helps,
    Steve C. Orr, MCSD, MVP
    http://Steve.Orr.net


    "Paul" <> wrote in message
    news:...
    > Hi, just wondering if there is a way to disable the back button of the
    > browser as I have a logoff page and would like to not allow the back
    > operation? Guessing there may be a way to do it through java script.
    > --
    > Paul G
    > Software engineer.
     
    Steve C. Orr [MVP, MCSD], Dec 11, 2004
    #2
    1. Advertising

  3. It is possible to disable history logging. But you should do every
    navigation using javascript. It is the difference between
    window.location.reload and window.location.replace.

    Replace overwrites the history entry while reload allows browser to log
    history. Also another difference between them is browser supporting
    versions.

    --
    Thanks,
    Yunus Emre ALPÖZEN



    "Paul" <> wrote in message
    news:...
    > ok thanks for the information. Do you use java script on the client side
    > to
    > close the window and if so what event corresponds to the back button
    > selection?
    >
    > "Steve C. Orr [MVP, MCSD]" wrote:
    >
    >> You'd think there would be, but there's not.
    >> A common approach is to close the window, and open a new one if you must.
    >> This new window will have no history so the back button will be disabled.
    >>
    >> --
    >> I hope this helps,
    >> Steve C. Orr, MCSD, MVP
    >> http://Steve.Orr.net
    >>
    >>
    >> "Paul" <> wrote in message
    >> news:...
    >> > Hi, just wondering if there is a way to disable the back button of the
    >> > browser as I have a logoff page and would like to not allow the back
    >> > operation? Guessing there may be a way to do it through java script.
    >> > --
    >> > Paul G
    >> > Software engineer.

    >>
    >>
    >>
     
    Yunus Emre ALPÖZEN, Dec 25, 2004
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. belgie

    back button - disable

    belgie, Jul 25, 2003, in forum: ASP .Net
    Replies:
    4
    Views:
    716
    Scott M.
    Jul 26, 2003
  2. Shalva

    Disable back button

    Shalva, Jan 15, 2004, in forum: ASP .Net
    Replies:
    1
    Views:
    633
    Chris Jackson
    Jan 15, 2004
  3. Ghafran Abbas
    Replies:
    0
    Views:
    4,316
    Ghafran Abbas
    Oct 12, 2004
  4. Raghu Raman

    How to disable the IE Back button

    Raghu Raman, Oct 28, 2004, in forum: ASP .Net
    Replies:
    6
    Views:
    10,883
    Raghu Raman
    Oct 29, 2004
  5. sylvia sil
    Replies:
    1
    Views:
    657
    Curt_C [MVP]
    Dec 29, 2004
Loading...

Share This Page