title: Save variable value after reloading in javascript
body: <p>I would like the <code>var</code> value to have the same value after refreshing, e.g if the button is pressed 5 times, then the user refreshes, the paragraph 'print' will show 6 instead of 1, which it is set to do currently.</p>
  
  <p>Here is my code:</p>
  
  <pre><code>var value = 1;
  $(document).ready(function() {
      $('#print').text(value);
  });
  
  $('#add1Button').click(function() {
      value = value + 1;
      $('#print').text(value);
  });
  </code></pre>