title: Submit form and save values to sessionStorage
body: <p>How can I save values from form to sessionStorage when the form is submitted? </p>
  
  <p>Something like this?</p>
  
  <pre><code>        &lt;form id="myForm" method="get" action="lista.html" rel="external" data-ajax="false" &gt;
  
          &lt;label for="autonumero"&gt; Anna autonumero &lt;/label&gt;
          &lt;input type='tel' name="autonumero" data-corners="false"/&gt;
  
  
          &lt;input type="submit" onclick="saveData()" value="OK" data-theme="a" data-corners="false" /&gt;
  
  
  
          &lt;script&gt; function savedata()
  { var input = document.getElementById("autonumero");
  sessionStorage.setItem("autonumero", input.value); 
  &lt;/script&gt; 
  
  
  
  
  
  
          &lt;/form&gt;
  </code></pre>
  
  <p>The form needs to be submitted also so just saving the values isn't enough</p>