W3C home > Mailing lists > Public > whatwg@whatwg.org > May 2010

[whatwg] Type Date

From: Schalk Neethling <schalk@ossreleasefeed.com>
Date: Fri, 7 May 2010 00:30:23 +0200
Message-ID: <013401caed6b$b9d97400$2d8c5c00$@com>
Just to rectify any misunderstanding, I love the date picker that Opera provides and others will hopefully do in turn but, my question is that currently using type=date only provides the option of selecting a date using the date picker. In a recent talk I gave on HTML 5 the question arose that well, what if the user wants to have both options on the same field?

My suggestion was to fall back to using a standard text input field and use JavaScript to add the date picker which will allow the user to enter the date manually if so desired. Are there any current plans to add this ability to type=date or is the fallback the best option?

Thanks,
Schalk

-----Original Message-----
From: Tab Atkins Jr. [mailto:jackalmage@gmail.com] 
Sent: Thursday, May 06, 2010 11:40 PM
To: Schalk Neethling
Cc: whatwg at lists.whatwg.org
Subject: Re: [whatwg] Type Date

On Thu, May 6, 2010 at 2:19 PM, Schalk Neethling <schalk at ossreleasefeed.com> wrote:
> Greetings,
>
> Are there any talks at the moment whether the type=date input will allow a user to enter a date manually or use the date picker or, should developers fall back to using a standard input field and add the date picker via JavaScript?

The purpose of <input type=date> is to allow the browser to supply the user with a datepicker.  Opera, for example, already does this.

If you would like to show a datepicker to users of all browsers, use feature detection (such as through the Modernizr script) to detect whether or not the browser support date inputs, and if not, supply the js version.

~TJ
Received on Thursday, 6 May 2010 15:30:23 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 16:59:23 UTC