[whatwg] RFC: <input type="username">

Eitan Adler eitanadlerlist at gmail.com
Tue May 4 00:08:26 PDT 2010

Use cases:
1) A screen reader that sees a form with a type=username and a
password field. The screen reader could just ask "Log in to this site?
[y/n]?". No further context would be needed.
2) UAs can more easily discover login forms and offer things such as
Firefox's Account Manager [1] or a "remember me" feature
3) Currently autofill for usernames looks for something like
id="username" or name="username". However on certain websites this
fails. Furthermore some websites offer a "find other members" feature
where you could type in a username. I've often seen these fields
filled in automatically with my name.
4) I'm sure there are others....

The proposal:
A type="username" is added to the input element. type="username" would
MUST only be used for the name that is used to log in to the site. It
MUST NOT be used for registration forms or anything else that requires
a username. A form MAY have up to one (but not more) type="username"
input field.

[1] http://www.mozilla.com/en-US/firefox/accountmanager/

More information about the whatwg mailing list