How to disable the back button in browser when user logout in asp.net c#

前端 未结 7 1987
名媛妹妹
名媛妹妹 2020-12-06 02:31

Our problem is we are able to clear session on logout.

But if a user clicks the back button then he/she can go through all previous screens.

But the advantag

7条回答
  •  难免孤独
    2020-12-06 03:08

    You need to force the cache to expire for this to work. I'm looking for the code sample for you.

    EDIT
    Found this for you, its already been addressed here on SO.

    Page.Response.Cache.SetCacheability(HttpCacheability.NoCache)
    

    Here...

提交回复
热议问题