1)AUTOCOMPLETE:- AUTOCOMPLETE attributes is having two features either on or off. If autocomplete is on then the browser automatically complete the values based on values that the user has entered before. This attribute works with form and the following input types: text, search, url, tel, email, password, datepickers, range, and color.
eg:
<form action="# " autocomplete="on">
<span style="Display:block;">First name:</span>
<input type="text" name="firstname" value="John>
<span style="Display:block;">Email:</span>
<input type="email" name="email" autocomplete="off">
<input type="submit">
</form>
Note:Autocomplete is not supported in opera browser.
2)AUTOFOCUS:- AUTOFOCUS specifies that an input element should automatically get focus when the page loads.
eg.
<input type="text" name="firstname" value="John autofocus>
Note: "First name" input field automatically get focus when the page loads.
The autofocus attribute of the input tag is not supported in Internet Explorer 9 and earlier versions.
3)FORM:- FORM specifies one or more forms an input element belongs to.
eg.
<form action="# " id="form1">
<span style="Display:block;">First name:</span>
<input type="text" name="firstname" value="John>
<input type="submit">
</form>
<span style="Display:block;">last name:</span>
<input type="text" name="lastname" form="form1">
Note: For more than one form, use a space-separated list of form ids.
Form attribute of the input tag is not supported in Internet Explorer 9 and earlier versions.
4)FORMACTION:- FORMACTION specifies the URL of a file that will process the input control when the form is submitted.It overrides action attribute.
eg.
<input type="submit" value="Submit">
<input type="submit" formaction="##"
value="Submit as admin">
Note: The formaction attribute of the input tag is not supported in Internet Explorer 9 and earlier versions.
5)FORMENCTYPE:- FORMENCTYPE attribute specifies how the form-data should be encoded.when submitting it to the server (only for forms with method="post").
It overrides the enctype attribute of the form element.
eg.
<form action="#" method="post">
<span style="Display:block;">First name:</span>
<input type="text" name="fname">
<input type="submit" value="Submit">
<input type="submit" formenctype="multipart/form-data" value="Submit as Multipart/form-data">
</form>
Note: It is not supported in Internet Explorer 9 and earlier versions.
0 Comment(s)