The action attribute defines the action to be performed when the form is submitted. The common way to submit a form to a server, is by using a submit button. Normally, the form is submitted to a web page on a web server, where a server-side script handles the data. Actions are implemented with this line:
HTML file: | Displayed by browser: |
---|---|
<form action="http://www.w3schools.com/html/action_page.php">
First name:<br /> <input type="text" name="firstname" value="Mickey"> <br /><br /> Last name:<br /> <input type="text" name="lastname" value="Mouse"> <br /><br /> <input type="submit" value="Submit"> </form> |
Notes: