submit a form code example
Example 1: javascript submit a form
document.getElementById("myFormID").submit();
Example 2: submit html
<input type="submit">
Example 3: how to use form on submit in html
<form onsubmit="myFunction()">
Enter name: <input type="text">
<input type="submit">
</form>