title: JS - How to submit form onclick and send submit button
body: <p>I need to submit form by button which is out of scope of the form by JavaSript.</p>
  
  <pre><code>&lt;form&gt;
    &lt;input name="data" type="text"&gt;
    &lt;input type="submit" name="send" id="send-button" style="display: none"&gt;
  &lt;/form&gt;
  
  &lt;button onclick="$('#send-button').click() || .submit()"&gt;&lt;/button&gt;
  </code></pre>
  
  <p>The button <strong>#send-button</strong> is visible and I need to send whole form to server. It means I receive <strong>$data</strong> and <strong>$send</strong> (both).</p>
  
  <p>Now I am getting just the <strong>$data</strong>.</p>
  
  <p>Any idea?</p>