Example
An HTML form with two input fields and one submit button:<form action="demo_form.asp" method="get">
First name: <input type="text" name="fname"><br>
Last name: <input type="text" name="lname"><br>
<input type="submit" value="Submit">
</form>
Teach Yourself by BH24 HTML Editor Tool!
The <form> tag is supported in all major browsers.
Definition and Usage
The <form> tag is used to create an HTML form for user input.The <form> element can contain one or more of the following form elements:
- <input>
- <textarea>
- <button>
- <select>
- <option>
- <optgroup>
- <fieldset>
- <label>