Please see my comment to the question. If you need to submit some HTTP request to the server side, I can see the following missing points:
1) Each input element should have the attribute
name
, the values of this attributes should be unique in the form. 2) the form element should have the attribute
method
, typically,
method="post"
, 3) the form element should have the attribute
action
. Its value should be your PHP script which handles the HTTP request.
Please see:
https://developer.mozilla.org/en-US/docs/Web/Guide/HTML/Forms[
^].
See also (you don't have to do it all):
https://developer.mozilla.org/en-US/docs/Web/API/FormData/Using_FormData_Objects[
^].
Frankly, if you need to do anything else, not sending HTTP request, you don't really need to use the form. But to use the form and all the request data, you need to handle it all in PHP, which quite easy, but is the whole different story. Please see:
http://php.net/manual/en/tutorial.forms.php[
^].
—SA