title: How to submit form and remain on the same page
body: <p>There is a similar question which demonstrates how to do it in jQuery. Unfortunately, I'm using prototype and translating the code isn't very straight forward. </p>
  
  <p><a href="https://stackoverflow.com/questions/5733808/submit-form-and-stay-on-same-page">Submit form and stay on same page?</a></p>
  
  <p>What needs to happen is the value (email) is posted to the page on the subDomain and the user does not get redirected. I do not have any control to edit the page on the subDomain. </p>
  
  <p>Any assistance would be appreciated. </p>
  
  <pre><code>function submitEmailForm(){
          var userEmail = $('Text').value;
          $('EmailForm').action = 'http://subDomain.myDomain.com/?email_address='+userEmail;
          $('EmailForm').request({ onComplete: function(){ return false;} });
      }
  
  &lt;form method="post" id="EmailForm" onsubmit="submitMobileEmailForm(); return false;"&gt;
            &lt;input type="text" id="Text"/&gt;
            &lt;input type="submit" id="Submit" value=""/&gt;
  &lt;/form&gt;
  </code></pre>