title: show display:none div after refresh
body: <p>Don't know how to put the question title correctly!
  I have a div that is displayed by button click. The problem is that if user goes to next page(by clicking another button) and then come back to the old page the div is not shown because page is refreshed, so user needs to click the button again to see the div.</p>
  
  <p>Is there any way to keep div displayed after button clicked for first time?</p>
  
  <pre><code>&lt;div id="tableDiv" style="display:none;" &gt;
  &lt;table&gt;
     &lt;td&gt;something&lt;/td&gt;
  &lt;/table&gt;
  &lt;/div&gt;
  
  &lt;input type="button" value="Show" onClick="showTable()"/&gt;
  
  &lt;script type="text/javascript"&gt;         
     function showTable() {
         document.getElementById('tableDiv').style.display = "block";
     }                
  &lt;/script&gt;
  </code></pre>