A web form has two parts: the HTML ‘front end’ and a back end form processor. The HTML front end part handles the presentation while the back end handles the form submissions (like saving the form submissions, sending emails etc).
The back end form processor script is usually written in languages like PHP, ASP or Perl.
The image below illustrates the concept:

- A visitor visits a web page that contains a form.
- The web browser displays the HTML form.
- The visitor fills in the form and submits
- The browser sends the submitted form data to the web server
- A form processor script running on the web server processes the form data
- A response page is sent back to the browser.
The HTML form tag
All the input elements should be enclosed within the opening and closing <form> tags like this:
<form>
The input elements go here….
</form>
The following are the attributes of the form tag:
action=”Link to the form processor script”
The action attribute points to the server side script (the ‘back end’) that handles the form submission. Usually, this will be a script (PHP,ASP, Perl) or a CGI program.
From: http://www.javascript-coder.com