[whatwg] Please consider adding a couple more datetime <input> types - type="year" and type="month-day"

Kit Grose kit at iqmultimedia.com.au
Mon Aug 9 18:47:41 PDT 2010


On 10/08/2010, at 10:44 AM, Tab Atkins Jr. wrote:

> On Mon, Aug 9, 2010 at 5:41 PM, Ryosuke Niwa <ryosuke.niwa at gmail.com> wrote:
>> On Mon, Aug 9, 2010 at 8:36 AM, Andy Mabbett <andy at pigsonthewing.org.uk>
>> wrote:
>>> 
>>> On Mon, August 9, 2010 15:10, Daniel Glazman wrote:
>>>> Le 09/08/10 03:11, Kit Grose a écrit :
>>>> 
>>>>> should the "year" field also permit the entry of BC/AD?
>>>> 
>>>> Or a jewish year? Or a muslim year? Or counting since the
>>>> first tooth of Carolus Magnus or the last onomatopoeia
>>>> pronounced by Hannibal during his crossing of the Alps?
>> 
>> All popular calendar systems should be supported.  What is the reason we
>> restrict ourselves to Gregorian calendar?
> 
> The Gregorian calendar is the de facto official calendar of the world.
> Mixing in other calendars is a horrendous nightmare with nearly zero
> benefit.
> 
> ~TJ


All the more reason for simply letting page authors define any fields they need using the existing input primitives like "number". I think putting the onus for this sort of investigation on the UA will simply mean this won't get implemented.

Is any of this discussion being had for the existing date type? The existing spec simply says a year must be "Four or more digits, representing year, where year > 0".

I think all of this is important discussion not explicitly related to the need for a new input of type "year". The question we need to identify is whether there's additional value (semantic or otherwise) in defining input type="year" distinctly from a textual/numeric input with name="year". The precise behaviour of any such field is surely dependent on an agreement that its existence is valuable.

—Kit


More information about the whatwg mailing list