HTML form Tag
HTML form Tag
The form tag is used to create an HTML form for user input. It is the gateway through which users contact or interact with the website owner. It serves many purposes.
Some form elements:-
- < input >
- < select >
- < input type="checkbox" >
- < input type="radio" >
- < textarea >
- < button >
- < option >
- < label >
- < output >
- < fieldset >
Attribute Explanation:-
Attribute | Value | Description |
accept-charset | character_set |
Specifies the character encodings that are to be used for the form submission |
action | URL |
Specifies where to send the form-data when a form is submitted |
autocomplete | on off |
Specifies whether a form should have autocomplete on or off |
enctype | application/x-www-form-urlencoded multipart/form-data text/plain |
Specifies how the form-data should be encoded when submitting it to the server (only for method="post") |
method | get post |
Specifies the HTTP method to use when sending form-data |
name | text | Specifies the name of a form |
rel | external help license next nofollow noopener noreferrer opener prev search |
Specifies the relationship between a linked resource and the current document |
target | _blank _self _parent _top |
Specifies where to display the response that is received after submitting the form |