title: send canvas image data via html form, and load data into new blank canvas page
body: <p>I have an HTML button that captures the canvas image using toDataURL(). I want to pass the data to a form element, which will send via formmail. I can get all other variables passed via hidden form elements, but the canvas data won't take. It must not be formatted properly to send. What is the correct syntax to send, if possible?</p>
  
  <p>In JavaScript</p>
  
  <pre><code>imgData = theCanvas.toDataURL();
  
  document.getElementById('theImageData').value=imgData;
  </code></pre>
  
  <p>In HTML</p>
  
  <pre><code>&lt;input type="hidden" name="theImageData" id="theImageData" value=""&gt;
  </code></pre>