html tutorial - autocomplete Attribute in HTML - html5 - html code - html form




Autocomplete attribute in html

Learn html - html tutorial - Autocomplete attribute in html - html examples - html programs

  • The autocomplete attribute is mused to enable autocomplete option for a form or an input file.
  • The autocomplete attribute allows the browser to predict the value.
  • Based on the earlier typed values. When the user starts to type in a field, the browser displays the options to fill in the field.

Syntax for autocomplete attribute in HTML:

<form autocomplete = “on | off”>

Differences between HTML 4.01 and HTML5 for autocomplete attribute:

HTML 4.01

  • HTML4 does not support autocomplete attribute.

HTML5

  • autocomplete attribute is new in HTML5.

Applies to:

Elements Attribute
<form> autocomplete
<input> autocomplete

autocomplete attribute value in HTML:

Value Description
on Specifies that autocomplete is on (enable)
off Specifies that autocomplete is off (disable)

Sample coding for autocomplete attribute in HTML:

Tryit<!DOCTYPE html>
<html>
    <body>
        <form action="auto.htm" method="get" autocomplete="on">
            First name: <input type="text" name="fname"><br>
            E-mail: <input type="email" name="email"><br>
            <input type="submit">
        </form>
    </body>
</html>

Code Explanation for autocomplete attribute in HTML:

autocomplete Attribute Code Explanation

  1. autocomplete attribute is used to enable the auto complete in the specified form.

Output for autocomplete attribute in HTML:

autocomplete Attribute Output

  1. When user type the “wi” the browser predict the value as” “wikitechy” which is user previously used.

Browser Support for autocomplete attribute in HTML:

17.0 5.0 4.0 5.2 9.6

Related Searches to autocomplete Attribute in html

Adblocker detected! Please consider reading this notice.

We've detected that you are using AdBlock Plus or some other adblocking software which is preventing the page from fully loading.

We don't have any banner, Flash, animation, obnoxious sound, or popup ad. We do not implement these annoying types of ads!

We need money to operate the site, and almost all of it comes from our online advertising.

Please add wikitechy.com to your ad blocking whitelist or disable your adblocking software.

×