English | 简体中文 | 繁體中文 | Русский язык | Français | Español | Português | Deutsch | 日本語 | 한국어 | Italiano | بالعربية
Die autocomplete-Eigenschaft legt fest, ob die automatische Vervollständigungsfunktion für das Eingabefeld aktiviert werden soll. Die automatische Vervollständigung ermöglicht es dem Browser, Werte vorherzusagen. Wenn der Benutzer mit der Eingabe im Feld beginnt, sollte der Browser Optionen anzeigen, die für das Ausfüllen des Felds verwendet werden können, basierend auf den früheren Eingaben.
HTML-Formular mit der automatischen Vervollständigungsfunktion aktiviert (und in einem Eingabefeld deaktiviert):
<!DOCTYPE html> <html> <head> <title>HTML: <input> autocomplete Eigenschaft - Grundlegende Anleitung (oldtoolbag.com)</title> <body> <form action="action_page.php" autocomplete="on"> Vorname: <input type="text" name="fname"><br> Nachname: <input type="text" name="lname"><br> E-mail: <input type="email" name="email" autocomplete="off"><br> <input type="submit"> </form> </body> </html>Testen Sie es heraus ‹/›
IEFirefoxOperChromeSafari
All major browsers support the autocomplete attribute.
Tip:In some browsers, you may need to enable the auto-complete feature for it to work (check under "Preferences" in the browser menu).
The autocomplete attribute specifies whether the auto-complete feature should be enabled for the input field.
The auto-complete feature allows the browser to predict values. When the user starts typing in the field, the browser should display options for filling the field based on the earlier entered values.
Note:The autocomplete attribute is applicable to the following <input> types: text, search, url, tel, email, password, datepickers, range, and color.
The autocomplete attribute is an HTML5 New Attribute Added.
<input autocomplete="on|off">
Value | Description |
---|---|
on | Default. Specify the enable auto-complete feature. |
off | Specify the disable auto-complete feature. |