Showing posts with label Disable browser back button after authentication. Show all posts
Showing posts with label Disable browser back button after authentication. Show all posts

Friday, 14 December 2012

Disable browser back button after authentication in asp.net application

To disable back button After login 
Place this code in the HTML head section of  Login.aspx  page

    <script type="text/javascript" language="javascript">
        function preventBack() { window.history.forward(); }
        setTimeout("preventBack()", 0);
        window.onunload = function () { null };

  </script>

Total Pageviews