I ran into this behavior (which I think is weird) where a button no longer posts back to ther server after I click on a the Firefox's back button. [more]
I'm not sure if I'm missing some incorrect settings whatsoever but it works on IE7. I'm hoping someone who runs into this might verify or some thoughts on why is behaves that way. Using Firefox 188.8.131.52, ASP.NET 2.0
Here is my code
ASPX (sorry no formatting but it's just a simple page with an ASP button)
<%@ Page AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" Language="C#" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<head id="Head1" runat="server">
<form id="form1" runat="server">
<asp:Button ID="Button1" runat="server" OnClick="Button1_Click" Text="Button" UseSubmitBehavior="false" /></div>
1. Load the page
2. Click on the button. Click event handler in server side runs and a GUID is displayed after page reloads
3. Click Back button. As far as my machine/browser behaves, no postback happens.
On the other hand, if using IE (7), step 3 still causes a postback.
It does seem that it has something to do with client side caching since if you uncomment the code in Page_Load, step 3 causes a postback. The only difference with IE though is that if say you have a textbox in the same page, you place some text in the textbox and you click the back button since no client side caching is made, you loose the contents of the textbox.
Installed FireBug to get some hint but for some reason it caused some intermittent behavior. Sometimes it works (posts back) sometimes it doesn't. Not sure though if it's FireBug causing the intermittent behavior but the "no postback behavior" predates the FireBug installation.
Haven't got the chance to dig deeper into this yet. Gotta get back to work 🙂 I hope I'm just not missing something obvious here…
__doPostBack and the Back Button by Rick Strahl – some possibly relevant information but not quite since in his case, the button click and checkbox check changed event both fire in the server side, in my case the page doesn't postback at all.