Skip to content

Instantly share code, notes, and snippets.

@Noyabronok
Created January 29, 2018 22:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Noyabronok/cdcf0d2dba44fec6c0cb0b151558ff52 to your computer and use it in GitHub Desktop.
Save Noyabronok/cdcf0d2dba44fec6c0cb0b151558ff52 to your computer and use it in GitHub Desktop.
example of form where chrome autofill works for all fields except address1
<!DOCTYPE html>
<head>
<title>Some Site</title>
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
</head>
<body>
<p>Some other website</p>
<form id="test-form" action="#" autocomplete="disabled">
First Name: <input type="text" name="fname" id="fname-id" autocomplete="given-name"><br/>
Last Name: <input type="text" name="lname" id="lname-id" autocomplete="family-name"><br/>
Address Line 1: <input type="text" name="address" id="address-id" autocomplete="disabled"><br/>
Address Line 2: <input type="text" name="addressl2" id="addressl2-id" autocomplete="address-line2"><br/>
City: <input type="text" name="city" id="city-id" autocomplete="address-level2"><br/>
State: <input type="text" name="state" id="state-id" autocomplete="address-level1"><br/>
Zip: <input type="text" name="zip" id="zip-id" autocomplete="postal-code"><br/>
Tel: <input type="tel" name="phone" id="tel-id" autocomplete="tel"><br/>
<input type="submit" value="Submit"/>
</form>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment