title: How Disable Browser Back Button only after Logout in mvc3.net
body: <p>I am using  FormsAuthentication for userlogin.
  I am having a problem after user logs out successfuly the back button is browser allows user to view pages.
  I tried using javascript</p>
  
  <pre><code> &lt;script type = "text/javascript" &gt;
          function preventBack() { window.history.forward(1); }
          setTimeout("preventBack()", 0);
          window.onunload = function () { null };
  &lt;/script&gt;
  </code></pre>
  
  <p>But back button is completly disabled.
  It worked bt,I dont want to disable back button functionality when user is logged in. i want my LOGGED IN user to use browser back button as normal. But once he choosed to log out, he is not allow to see any of  contents by pressing Back. 
  I also tried using</p>
  
  <pre><code>Session.Abandon();
   Response.Cache.SetCacheability(HttpCacheability.NoCache);
   Response.Cache.SetExpires(DateTime.Now);
  </code></pre>
  
  <p>But this is also not working.how do I fix this?</p>