title: Why does pressing a command button multiple times results in an increase in List size in IE but not in Firefox?
body: <p>I am facing a strange problem. Consider:</p>
  
  <p>Here is a datatable,</p>
  
  <pre><code> &lt;t:dataTable value="#{details.beanList}"
                  var="detailsVariable" 
                   preserveDataModel="false" id="someId"
                   rowIndexVar="rowIndex"&gt;
  
                  &lt;h:column &gt;
                      &lt;f:facet name="header"&gt;
                          &lt;h:panelGrid align="center"&gt;
                              &lt;h:outputText value="LINE NO." /&gt;
                          &lt;/h:panelGrid&gt;
                          &lt;h:panelGrid align="center"&gt;
                              &lt;h:outputText value="(#{listInOtherBean.listSize})" /&gt;
                          &lt;/h:panelGrid&gt;
                      &lt;/f:facet&gt;
                      &lt;h:outputText value="#{rowIndex+1}" /&gt;
                  &lt;/h:column&gt; 
  </code></pre>
  
  <p>and there is a <code>command button</code> above this datatable that refreshes data(gets the latest list from the database.)</p>
  
  <p>When I press this button and keep on pressing before that page refreshes as response to the form submit request, this value <code>#{listInOtherBean.listSize}</code> will increase by an unknown factor in IE whereas it will be fixed in Firefox.</p>
  
  <p>Attached Screenshots:</p>
  
  <p><strong><em>1)</em></strong> For <code>Mozilla Firefox</code>, 11876 is the list size which is reflected correctly and it will not change no matter how many times a user presses this button and keep on pressing before that page refreshes as response to the form submit request.</p>
  
  <p><img src="https://i.stack.imgur.com/C8Ukz.jpg" alt="enter image description here"></p>
  
  <p>2) For <code>Internet Explorer</code>, considering 3 times that button was pressed,</p>
  
  <p><img src="https://i.stack.imgur.com/lfevm.jpg" alt="enter image description here"></p>
  
  <p>Do notice one thing that <code>11876 * 3 = 35628 != 37943</code>, that the reason why I aforementioned increase by an <code>unknown factor</code>.</p>
  
  <p><strong>NOTE:</strong>
  It would be of no benefit if you imitate the problem like this,</p>
  
  <pre><code>&lt;h:form id="ngliform"&gt;
      &lt;h:commandButton action="#{refreshResetBean.refreshData}"
          id="refreshDataBtn" value="Refresh Data" style="margin-top:8px"
          onclick="document.getElementById('ngliform:resetFilterBtn').disabled=true;" /&gt;
      &lt;br /&gt;
      &lt;h:dataTable value="#{refreshResetBean.list}" var="listItem"&gt;
          &lt;h:column &gt;
              &lt;f:facet name="header"&gt;
                  &lt;h:panelGrid align="center"&gt;
                      &lt;h:outputText value="LINE NO." /&gt;
                  &lt;/h:panelGrid&gt;
                  &lt;h:panelGrid align="center"&gt;
                      &lt;h:outputText value="(#{refreshResetBean.listSize})" /&gt;
                  &lt;/h:panelGrid&gt;
              &lt;/f:facet&gt;
              &lt;h:outputText value="#{listItem}" /&gt;
          &lt;/h:column&gt;
      &lt;/h:dataTable&gt;
  &lt;/h:form&gt;
  </code></pre>
  
  <p>and the managed bean,</p>
  
  <pre><code>    List&lt;String&gt; list;
  
      public RefreshResetBean() {
          list = new ArrayList&lt;String&gt;();
          for (Integer i = 0; i &lt; 10; i++) {
              list.add(i.toString());
          }
      }
  
      public String refreshData() {
          try {
              Thread.sleep(10000);
          } catch (InterruptedException e) {
              e.printStackTrace();
          }
          return null;
      }
  
      public List&lt;String&gt; getList() {
          return list;
      }
  
      public Integer listSize;
  
      public Integer getListSize() {
          listSize = list.size();
          return listSize;
      }
  </code></pre>
  
  <p>It will be visualized with the correct list size in all 3 browsers, <code>IE, MF, Chrome</code> &amp; the list size won't change no matter how many times button is pressed.</p>
  
  <p><img src="https://i.stack.imgur.com/7kduF.jpg" alt="enter image description here"></p>
  
  <p>The website is not developed by me and there is too much code to get through. But I am amazed why the difference in <code>IE and MF</code> &amp; I want the case to as reflected in MF?</p>
  
  <p>Any suggestions? </p>