You are here : htmlHTML 5input

<input> - HTML 5

The <input> tag specifies an input field where the user can enter data.

<input> elements are used within a <form> element to declare input controls that allow users to input data.

An input field can vary in many ways, depending on the type attribute.


Syntax

    <form     action="demo_form.asp">     First name: <input type="text" name="fname"><br>         Last name:     <input type="text" name="lname"><br>         <input type="submit" value="Submit">    </form>


Example

    <form     action="demo_form.asp">     First name: <input type="text" name="fname"><br>         Last name:     <input type="text" name="lname"><br>         <input type="submit" value="Submit">    </form>


Output / Return Value


Limitations


Alternatives / See Also


Reference