W3C home > Mailing lists > Public > www-validator@w3.org > March 2015

[VE][html5] Email Input Attributes

From: Christopher Dickinson <chris.w.dickinson@gmail.com>
Date: Sat, 28 Mar 2015 10:55:54 -0400
Message-ID: <CALafDytF-KYykj=5LD+ozHCVvixYBxL=ZFnJfQiJkbE6Pf9z4Q@mail.gmail.com>
To: www-validator@w3.org
I am using an email input field in my webpage; the code looks like:

<input type="email" id="email" name="email" size="80" maxlength="80" value=""
required="required" />

When I run my page through the W3 HTML5 Validator, I get the following two

   - Attribute maxlength is only allowed when the input type is e-mail,
   password, search, tel, text, or url.
   - Attribute required is only allowed when the input type is checkbox,
   date, datetime, datetime-local, e-mail, file, month, number, password,
   radio, search, tel, text, time, url, or week.

It's an email input type, but the validator seems to reject it; the
warnings don't seem to make sense.
Received on Monday, 30 March 2015 08:21:38 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 22:59:47 UTC