https://wiki.whatwg.org/api.php?action=feedcontributions&user=Tom+Morris&feedformat=atomWHATWG Wiki - User contributions [en]2024-03-28T19:22:04ZUser contributionsMediaWiki 1.39.3https://wiki.whatwg.org/index.php?title=Time_element_accepted&diff=9044Time element accepted2013-02-25T12:36:50Z<p>Tom Morris: /* year week only */ removing the no examples bit - there is now one example</p>
<hr />
<div>Summary: Research, data, use cases, issues, and enhancements related to the [http://www.whatwg.org/specs/web-apps/current-work/multipage/text-level-semantics.html#the-time-element HTML5 <code>time</code> element] (see also [http://www.w3.org/TR/html5/text-level-semantics.html#the-time-element W3C TR time snapshot]) that have been adopted in HTML (and HTML5).<br />
<br />
HTML5's new &lt;time&gt; element presents a huge opportunity to improve the publishing of datetime information on the web, the biggest opportunity since the introduction of hCalendar and other time-based microformats.<br />
<br />
The time element has been improved through the research done on this page.<br />
<br />
For other proposals for improving the &lt;time&gt; element, see:<br />
* [[Time element]]<br />
<br />
[[User:Tantek|Tantek]] (and other proposal authors).<br />
<br />
<br />
== year only ==<br />
;Status<br />
:[http://html5.org/tools/web-apps-tracker?from=6826&to=6827 2011-11-18] '''Adopted in WHATWG HTML.''' <br />
;Summary<br />
:The time element should accept just a year.<br />
;ISO8601 syntax<br />
:YYYY<br />
=== year only use cases ===<br />
use case research:<br />
* http://microformats.org/wiki/birthday-examples#year_only<br />
* use cases in VCARDDAV & EDTF - see external links<br />
* [http://en.wikipedia.org/wiki/Template:Start_date Wikipedia 'Start date' template] - thousands of [http://bit.ly/aKhmdQ YYYY instances]<br />
* [http://en.wikipedia.org/w/index.php?title=Ethan_Stiefel&oldid=377074089 Wikipedia infobox with YYYY birthdate] (unknown MM-DD)<br />
* Copyright notices are often year-only; e.g. that at the foot of [http://www.rspb.org.uk/groups/suttoncoldfield/]<br />
* In biological taxonomy, a species', genus' or other rank's ''authority'' (the person who named it, and the year they did so) always includes a whole-year date value. For example:<br />
**Barn Owl, ''Tyto alba'' (Scopoli, 1769) [http://en.wikipedia.org/wiki/Barn_owl]<br />
**Strigiformes (Wagler, 1830) [http://en.wikipedia.org/wiki/Owl]<br />
* Photo date taken<br />
** [http://laughingmeme.org/2011/06/02/flourishes-craftsmanship-dates-history-and-flickr/ Flickr supports year and circa dates] - "Flickr taken dates come in 4 levels of granularity, exact, year-month, year, and circa."<br />
*Citations from a bibliography which list two or more works by the same author disambiguate them by year<br />
*Commerce<br />
** "a piece of jewellery hallmarked 1933"<br />
** "a 1973 Chevy"<br />
*Sport<br />
**2008 Olympics<br />
**1966 World Cup<br />
*Awards<br />
**"1973 Oscar for best film"<br />
**"1988 Nobel Peace Prize"<br />
*Restyling dates for localisation and to follow user conventions<br />
**2010 to 平22年 to 2010年 (all acceptable ways to represent 2010 in Japan)<br />
* Relative dates in texts: news websites and blogs often use phrases such as<br />
** "damages during last year's Gaza offensive" [http://www.un.org/apps/news/story.asp?NewsID=33559],<br />
** "recession next year almost inevitable" [http://www.reuters.com/article/idUSTRE65E5K520100615]<br />
<br />
=== year only discussion ===<br />
<div class="discussion"><br />
Opinions / discussion:<br />
* +1 [[Faruk]] (per [http://www.w3.org/Bugs/Public/show_bug.cgi?id=7145 Bug 7145 - Valid date strings should accept ambiguous inputs, like "2009" or "2007-01"]) One example is the very common archive view found on most blogs, which contain distinct links or headers for each year, each month per year, and often each date within a chosen or highlighted month. Currently, the <code>&lt;time&gt;</code> element only allows for <code>datetime</code> values as precise as a specific day, e.g. YYYY-MM-DD.<br />
* -1 [[Hixie]] - "Without clear use cases, I don't intend to change the spec here." (ibid)<br />
* +1 [[Tantek]] (per [http://www.zeldman.com/superfriends/guide/#time HTML5 Super Friends Technical Details: time element])<br />
* +1 [[User:Pigsonthewing|Andy Mabbett]] (Per use cases in VCARDDAV & EDTF - see external links)<br />
* +1 [[User:Philipj|Philip Jägenstedt]] - for marking up [http://musicbrainz.org/release/aa82c130-c734-4d9c-b06a-5bba9b44295d.html release dates on e.g. MusicBrainz] where the date is given as YYYY, YYYY-MM or YYYY-MM-DD.<br />
* +1 [[User:asbjornu|Asbjørn Ulsberg]] - for marking up [http://en.wikipedia.org/wiki/World_war_2 years on Wikipedia] ("...global military conflict lasting from 1939 to 1945...").<br />
* +1 [[User:GlennJones|Glenn Jones]] - This is often used to format date description for resume's Stackoverflow http://careers.stackoverflow.com/klmr I could list more cases in the wild. Like YYYY, YYYY-MM or YYYY-MM-DD its part of the http://www.w3.org/TR/NOTE-datetime profile.<br />
* +1 [[User:Oli|Oli Studholme]] This would be useful for semantically marking up years, as in Japan there’s an additional era-based method of representing years (and even Japanese people find it difficult to convert between them), and it would allow the browser to automatically display the user-preferred format. It would also also enable browser-based localisation (adding a 年 after the year). Finally it would be useful for marking up future imprecise dates (e.g. events being planned), allowing someone to add these dates to a calendar automatically (rather than marking up teh events plus manually adding them to a calendar). ref: [http://lists.whatwg.org/htdig.cgi/whatwg-whatwg.org/2010-August/028025.html email to WHATWG]<br />
* +1 [[User:Ocolon|Martin Janecke]] - This would be great to mark up relative dates ("next year I will …") that actually refer to an absolute date in the context of the text and the publication date of the text respectively.<br />
* +1 [[User:Drublic|drublic]] - As input-fields support `year` the datetime-attribute as it is (was until <time datetime="2011-10-20">yesterday</time>) should also allow users to define year-only dates. Furthermore it will help making newspapers, wikis and quotations more accessible and semantically powerful.<br />
* ...<br />
</div><br />
<br />
=== year only related posts ===<br />
Related posts (listed with quotes directly related to year only) :<br />
* [http://pigsonthewing.org.uk/dates-and-coordinates-in-html5/ 2009-02-23 Dates and coordinates in HTML5] blog post by Andy Mabbett - <blockquote cite="http://pigsonthewing.org.uk/dates-and-coordinates-in-html5/">hCalendar microformats are already used to mark up imprecise dates (“June 1977″; “2009″). ISO8601 already supports them. Why not HTML5?</blockquote><br />
* [http://www.brucelawson.co.uk/2009/html-5-politics-and-me/ 2009-02-25 HTML 5, politics and me] blog post by Bruce Lawson - look for mention of "time element" which mentions: <blockquote cite="http://www.brucelawson.co.uk/2009/html-5-politics-and-me/">I see no reason why authors shouldn’t be able to mark up ... dates like ... “1935″ which are currently disallowed by the spec</blockquote><br />
<br />
=== year only next steps ===<br />
Per this edit/comment from Ian: http://lists.w3.org/Archives/Public/public-html-diffs/2010Aug/0234.html<br />
<br />
We need to help create a CSS feature for styling dates to local conventions (e.g. 2000-12-31 vs 31-12-2000 vs 12-31-2000 vs Japanese conventions for year and year-month). Once such a CSS feature exists, it will apparently provide additional weight for including year-only dates in the time element.<br />
<br />
<br />
== year month only ==<br />
;Status<br />
:[http://html5.org/tools/web-apps-tracker?from=6826&to=6827 2011-11-18] '''Adopted in WHATWG HTML.''' <br />
;Summary<br />
:The time element should accept just a year and a month.<br />
;ISO8601 syntax<br />
:YYYY-MM<br />
<br />
=== year month use cases ===<br />
* Blog/publishing archive pages - see Benward.me, ablognotlimited.com (need specific links to archive pages)<br />
** http://www.flickr.com/photos/tantek/archives/<br />
** [http://lists.whatwg.org/htdig.cgi/help-whatwg.org/ whatwg's own mailing list archives] (!)<br />
* output equivalent of <code>&lt;input type="month"&gt;</code>, see [[Time_element#impedance_match_new_date_time_inputs|impedance match new date time inputs]].<br />
* use cases in VCARDDAV & EDTF - see external links<br />
* [http://en.wikipedia.org/wiki/Template:Start_date Wikipedia 'Start date' template] - thousands of [http://bit.ly/aKhmdQ YYYY-MM instances]<br />
* Photo date taken<br />
** [http://laughingmeme.org/2011/06/02/flourishes-craftsmanship-dates-history-and-flickr/ Flickr supports year-month dates] - "Flickr taken dates come in 4 levels of granularity, exact, year-month, year, and circa."<br />
* Credit/ debit card expiry dates, entered into, then republished for verification on, e-commerce sites (security concerns prohibit use of example URL)<br />
* Restyling dates for localisation and to follow user conventions<br />
** 2010-08 to 08-2010 to 平22年8月 to 2010年8月 (all acceptable ways to represent August 2010 in Japan)<br />
* Relative dates in text: news websites, blogs and statistical institutes often use phrases like:<br />
** "in June 2010, the turnover […] decreased by 10.5% compared to the same month of the previous year." [http://www.nsi.bg/eventen.php?n=568]<br />
** "George W. Bush leaves office in January next year" [http://afp.google.com/article/ALeqM5hm2kKrBzl5p5Psm-EryzKK_m8H_A]<br />
<br />
=== year month discussion ===<br />
<div class="discussion"><br />
Opinions / discussion:<br />
* +1 [[Faruk]] (per [http://www.w3.org/Bugs/Public/show_bug.cgi?id=7145 Bug 7145 - Valid date strings should accept ambiguous inputs, like "2009" or "2007-01"]) One example is the very common archive view found on most blogs, which contain distinct links or headers for each year, each month per year, and often each date within a chosen or highlighted month. Currently, the <code>&lt;time&gt;</code> element only allows for <code>datetime</code> values as precise as a specific day, e.g. YYYY-MM-DD.<br />
* -1 [[Hixie]] - "Without clear use cases, I don't intend to change the spec here." (ibid)<br />
* +1 [[User:Tantek|Tantek]] I think the blog archives use case (where blogs often link to their archives by a specific month and year) is sufficient to justify adding this capability to the time element. Content hosting sites like Flickr also list archives by specific year/month, e.g. see http://www.flickr.com/photos/tantek/archives/<br />
* +1 [[User:Pigsonthewing|Andy Mabbett]] (Per use cases in VCARDDAV & EDTF - see external links)<br />
* +1 [[User:Philipj|Philip Jägenstedt]] - for marking up [http://musicbrainz.org/release/aa82c130-c734-4d9c-b06a-5bba9b44295d.html release dates on e.g. MusicBrainz] where the date is given as YYYY, YYYY-MM or YYYY-MM-DD.<br />
* +1 [[User:asbjornu|Asbjørn Ulsberg]] - for marking up [http://en.wikipedia.org/wiki/World_war_2#Japanese_invasion_of_China month+year on Wikipedia] ("In July 1937, Japan captured the former Chinese imperial capital of Beiping...").<br />
* +1 [[User:GlennJones|Glenn Jones]] - This is the most commonly used format date description for Resume's. Linked-in use it http://www.linkedin.com/in/steveganz and Stackoverflow http://careers.stackoverflow.com/klmr I could list many more cases in the wild.<br />
* +1 [[User:Oli|Oli Studholme]] As with the year example above, this would be useful for semantically marking up year-month dates, as in Japan there’s an additional era-based method of representing years (and even Japanese people find it difficult to convert between them), and it would allow the browser to automatically display the user-preferred format. It would also also enable browser-based localisation (adding a 年 after the year, and 月 after the month). Having this data semantically notated would help make the use in Japan of 2-digit years on credit cards and in e-commerce more accessible. Finally it would be useful for marking up future imprecise dates (e.g. events being planned), allowing someone to add these dates to a calendar automatically (rather than marking up teh events plus manually adding them to a calendar). [ref: [http://lists.whatwg.org/htdig.cgi/whatwg-whatwg.org/2010-August/028025.html email to WHATWG]]<br />
* +1 [[User:Ocolon|Martin Janecke]] - This would be great to mark up relative dates ("next January I will …") that actually refer to an absolute date in the context of the text and the publication date of the text respectively.<br />
* ...<br />
</div><br />
<br />
=== year month related posts ===<br />
Related posts (listed with quotes directly related to year-month) :<br />
* [http://pigsonthewing.org.uk/dates-and-coordinates-in-html5/ 2009-02-23 Dates and coordinates in HTML5] blog post by Andy Mabbett - <blockquote cite="http://pigsonthewing.org.uk/dates-and-coordinates-in-html5/">hCalendar microformats are already used to mark up imprecise dates (“June 1977″; “2009″). ISO8601 already supports them. Why not HTML5?</blockquote><br />
* [http://www.brucelawson.co.uk/2009/html-5-politics-and-me/ 2009-02-25 HTML 5, politics and me] blog post by Bruce Lawson - look for mention of "time element" which mentions: <blockquote cite="http://www.brucelawson.co.uk/2009/html-5-politics-and-me/">I see no reason why authors shouldn’t be able to mark up ... dates like “July 2008″ ... which are currently disallowed by the spec</blockquote><br />
* [http://www.brucelawson.co.uk/2009/marking-up-a-blog-with-html-5-part-2/#time 2009-03-06 Marking up a blog with HTML 5 (part 2) : Time] blog post by Bruce Lawson: <blockquote>I suggest the spec be amended to allow dates like "July 1966"</blockquote><br />
* [http://www.brucelawson.co.uk/2009/html-5-whats-hot-whats-not/ 2009-08-20 HTML 5: what’s hot, what’s not] blog post by Bruce Lawson - see section on TIME which explicitly mentions: <blockquote cite="http://www.brucelawson.co.uk/2009/html-5-whats-hot-whats-not/">The time element is still hamstrung by not being able to markup ... dates like “December 1935″</blockquote><br />
* [http://adactio.com/journal/1604/ 2009-08-30 HTML5 and me] blog post by Jeremy Keith - see section on "time" which explicitly mentions <blockquote cite="http://adactio.com/journal/1604/">make a piece of information like “April 1912” machine-readable</blockquote><br />
* [http://html5doctor.com/the-time-element/ 2010-02-09 The time element (and microformats)] blog post on HTML5 Doctor by Bruce Lawson - mentions: <blockquote>The only trouble with &lt;time&gt; is that the <nowiki>[sic]</nowiki> it must contain positive date on the Proleptic Gregorian calendar, meaning you can’t encode a date before the Christian Era. Neither can you encode imprecise dates such as “July 1904″.</blockquote><br />
<br />
=== year month next steps ===<br />
Per this edit/comment from Ian: http://lists.w3.org/Archives/Public/public-html-diffs/2010Aug/0234.html<br />
<br />
We need to help create a CSS feature for styling dates to local conventions (e.g. 2000-12-31 vs 31-12-2000 vs 12-31-2000 vs Japanese conventions for year and year-month). Once such a CSS feature exists, it will apparently provide additional weight for including year-month dates in the time element.<br />
<br />
== year week only ==<br />
;Status<br />
:[http://html5.org/tools/web-apps-tracker?from=6826&to=6827 2011-11-18] '''Adopted in WHATWG HTML.''' <br />
;Summary<br />
:The time element should accept just a year and a week number.<br />
;ISO8601 syntax<br />
:YYYY-WNN<br />
;use case research<br />
:OpenStreetMap's opening_hours tag allows specification of opening hours (of business, shops, parks etc.) by week number. See [http://www.openstreetmap.org/browse/way/40879988 example], [https://wiki.openstreetmap.org/wiki/Key:opening_hours documentation]<br />
:output equivalent of <code>&lt;input type="week"&gt;</code>, see [[Time_element#impedance_match_new_date_time_inputs|impedance match new date time inputs]] above.<br />
<br />
;reasoning<br />
:to provide the output equivalent of <code>&lt;input type="week"&gt;</code><br />
<br />
See [[Time_element#impedance_match_new_date_time_inputs|impedance match new date time inputs]] above.<br />
<br />
<div class="discussion"><br />
Opinions / discussion:<br />
* +1 [[Tantek]] per good design of impedance matching date time inputs.<br />
* ...<br />
</div><br />
<br />
== month day only ==<br />
;Status<br />
:[http://html5.org/tools/web-apps-tracker?from=6826&to=6827 2011-11-18] '''Adopted in WHATWG HTML.''' <br />
;Summary<br />
:The time element should accept just a month and a day.<br />
;ISO8601 syntax<br />
:--MM-DD<br />
;use case research<br />
:http://microformats.org/wiki/birthday-examples#month_and_day_only<br />
:[http://www.ietf.org/mail-archive/web/vcarddav/current/msg00999.html use cases discussed in VCARDDAV] & EDTF - see external links<br />
:Facebook - allows users to elect to show their birthday as, for example, "17 December", with no year.<br />
<br />
<div class="discussion"><br />
Opinions / discussion:<br />
* +1 [[Tantek]] (per [http://www.zeldman.com/superfriends/guide/#time HTML5 Super Friends Technical Details: time element])<br />
* +1 "radiz" implied support for --MM-DD with the use case question: "How to use &lt;time&gt; with a date in astrology?" in the article http://html5doctor.com/your-questions-answered-6/<br />
* +1 [[User:Pigsonthewing|Andy Mabbett]] (Per [http://www.ietf.org/mail-archive/web/vcarddav/current/msg00999.html use cases discussed in VCARDDAV] & EDTF, e.g. birthdays, wedding anniversaries - see external links)<br />
** [http://portablecontacts.net/draft-spec.html#anchor16 Portable contacts allows this] using a "0000" year value.<br />
* ...<br />
</div><br />
== See Also ==<br />
* [[Time element]]</div>Tom Morrishttps://wiki.whatwg.org/index.php?title=Time_element_accepted&diff=9043Time element accepted2013-02-25T12:36:03Z<p>Tom Morris: /* year week only */ adding OpenStreetMap example</p>
<hr />
<div>Summary: Research, data, use cases, issues, and enhancements related to the [http://www.whatwg.org/specs/web-apps/current-work/multipage/text-level-semantics.html#the-time-element HTML5 <code>time</code> element] (see also [http://www.w3.org/TR/html5/text-level-semantics.html#the-time-element W3C TR time snapshot]) that have been adopted in HTML (and HTML5).<br />
<br />
HTML5's new &lt;time&gt; element presents a huge opportunity to improve the publishing of datetime information on the web, the biggest opportunity since the introduction of hCalendar and other time-based microformats.<br />
<br />
The time element has been improved through the research done on this page.<br />
<br />
For other proposals for improving the &lt;time&gt; element, see:<br />
* [[Time element]]<br />
<br />
[[User:Tantek|Tantek]] (and other proposal authors).<br />
<br />
<br />
== year only ==<br />
;Status<br />
:[http://html5.org/tools/web-apps-tracker?from=6826&to=6827 2011-11-18] '''Adopted in WHATWG HTML.''' <br />
;Summary<br />
:The time element should accept just a year.<br />
;ISO8601 syntax<br />
:YYYY<br />
=== year only use cases ===<br />
use case research:<br />
* http://microformats.org/wiki/birthday-examples#year_only<br />
* use cases in VCARDDAV & EDTF - see external links<br />
* [http://en.wikipedia.org/wiki/Template:Start_date Wikipedia 'Start date' template] - thousands of [http://bit.ly/aKhmdQ YYYY instances]<br />
* [http://en.wikipedia.org/w/index.php?title=Ethan_Stiefel&oldid=377074089 Wikipedia infobox with YYYY birthdate] (unknown MM-DD)<br />
* Copyright notices are often year-only; e.g. that at the foot of [http://www.rspb.org.uk/groups/suttoncoldfield/]<br />
* In biological taxonomy, a species', genus' or other rank's ''authority'' (the person who named it, and the year they did so) always includes a whole-year date value. For example:<br />
**Barn Owl, ''Tyto alba'' (Scopoli, 1769) [http://en.wikipedia.org/wiki/Barn_owl]<br />
**Strigiformes (Wagler, 1830) [http://en.wikipedia.org/wiki/Owl]<br />
* Photo date taken<br />
** [http://laughingmeme.org/2011/06/02/flourishes-craftsmanship-dates-history-and-flickr/ Flickr supports year and circa dates] - "Flickr taken dates come in 4 levels of granularity, exact, year-month, year, and circa."<br />
*Citations from a bibliography which list two or more works by the same author disambiguate them by year<br />
*Commerce<br />
** "a piece of jewellery hallmarked 1933"<br />
** "a 1973 Chevy"<br />
*Sport<br />
**2008 Olympics<br />
**1966 World Cup<br />
*Awards<br />
**"1973 Oscar for best film"<br />
**"1988 Nobel Peace Prize"<br />
*Restyling dates for localisation and to follow user conventions<br />
**2010 to 平22年 to 2010年 (all acceptable ways to represent 2010 in Japan)<br />
* Relative dates in texts: news websites and blogs often use phrases such as<br />
** "damages during last year's Gaza offensive" [http://www.un.org/apps/news/story.asp?NewsID=33559],<br />
** "recession next year almost inevitable" [http://www.reuters.com/article/idUSTRE65E5K520100615]<br />
<br />
=== year only discussion ===<br />
<div class="discussion"><br />
Opinions / discussion:<br />
* +1 [[Faruk]] (per [http://www.w3.org/Bugs/Public/show_bug.cgi?id=7145 Bug 7145 - Valid date strings should accept ambiguous inputs, like "2009" or "2007-01"]) One example is the very common archive view found on most blogs, which contain distinct links or headers for each year, each month per year, and often each date within a chosen or highlighted month. Currently, the <code>&lt;time&gt;</code> element only allows for <code>datetime</code> values as precise as a specific day, e.g. YYYY-MM-DD.<br />
* -1 [[Hixie]] - "Without clear use cases, I don't intend to change the spec here." (ibid)<br />
* +1 [[Tantek]] (per [http://www.zeldman.com/superfriends/guide/#time HTML5 Super Friends Technical Details: time element])<br />
* +1 [[User:Pigsonthewing|Andy Mabbett]] (Per use cases in VCARDDAV & EDTF - see external links)<br />
* +1 [[User:Philipj|Philip Jägenstedt]] - for marking up [http://musicbrainz.org/release/aa82c130-c734-4d9c-b06a-5bba9b44295d.html release dates on e.g. MusicBrainz] where the date is given as YYYY, YYYY-MM or YYYY-MM-DD.<br />
* +1 [[User:asbjornu|Asbjørn Ulsberg]] - for marking up [http://en.wikipedia.org/wiki/World_war_2 years on Wikipedia] ("...global military conflict lasting from 1939 to 1945...").<br />
* +1 [[User:GlennJones|Glenn Jones]] - This is often used to format date description for resume's Stackoverflow http://careers.stackoverflow.com/klmr I could list more cases in the wild. Like YYYY, YYYY-MM or YYYY-MM-DD its part of the http://www.w3.org/TR/NOTE-datetime profile.<br />
* +1 [[User:Oli|Oli Studholme]] This would be useful for semantically marking up years, as in Japan there’s an additional era-based method of representing years (and even Japanese people find it difficult to convert between them), and it would allow the browser to automatically display the user-preferred format. It would also also enable browser-based localisation (adding a 年 after the year). Finally it would be useful for marking up future imprecise dates (e.g. events being planned), allowing someone to add these dates to a calendar automatically (rather than marking up teh events plus manually adding them to a calendar). ref: [http://lists.whatwg.org/htdig.cgi/whatwg-whatwg.org/2010-August/028025.html email to WHATWG]<br />
* +1 [[User:Ocolon|Martin Janecke]] - This would be great to mark up relative dates ("next year I will …") that actually refer to an absolute date in the context of the text and the publication date of the text respectively.<br />
* +1 [[User:Drublic|drublic]] - As input-fields support `year` the datetime-attribute as it is (was until <time datetime="2011-10-20">yesterday</time>) should also allow users to define year-only dates. Furthermore it will help making newspapers, wikis and quotations more accessible and semantically powerful.<br />
* ...<br />
</div><br />
<br />
=== year only related posts ===<br />
Related posts (listed with quotes directly related to year only) :<br />
* [http://pigsonthewing.org.uk/dates-and-coordinates-in-html5/ 2009-02-23 Dates and coordinates in HTML5] blog post by Andy Mabbett - <blockquote cite="http://pigsonthewing.org.uk/dates-and-coordinates-in-html5/">hCalendar microformats are already used to mark up imprecise dates (“June 1977″; “2009″). ISO8601 already supports them. Why not HTML5?</blockquote><br />
* [http://www.brucelawson.co.uk/2009/html-5-politics-and-me/ 2009-02-25 HTML 5, politics and me] blog post by Bruce Lawson - look for mention of "time element" which mentions: <blockquote cite="http://www.brucelawson.co.uk/2009/html-5-politics-and-me/">I see no reason why authors shouldn’t be able to mark up ... dates like ... “1935″ which are currently disallowed by the spec</blockquote><br />
<br />
=== year only next steps ===<br />
Per this edit/comment from Ian: http://lists.w3.org/Archives/Public/public-html-diffs/2010Aug/0234.html<br />
<br />
We need to help create a CSS feature for styling dates to local conventions (e.g. 2000-12-31 vs 31-12-2000 vs 12-31-2000 vs Japanese conventions for year and year-month). Once such a CSS feature exists, it will apparently provide additional weight for including year-only dates in the time element.<br />
<br />
<br />
== year month only ==<br />
;Status<br />
:[http://html5.org/tools/web-apps-tracker?from=6826&to=6827 2011-11-18] '''Adopted in WHATWG HTML.''' <br />
;Summary<br />
:The time element should accept just a year and a month.<br />
;ISO8601 syntax<br />
:YYYY-MM<br />
<br />
=== year month use cases ===<br />
* Blog/publishing archive pages - see Benward.me, ablognotlimited.com (need specific links to archive pages)<br />
** http://www.flickr.com/photos/tantek/archives/<br />
** [http://lists.whatwg.org/htdig.cgi/help-whatwg.org/ whatwg's own mailing list archives] (!)<br />
* output equivalent of <code>&lt;input type="month"&gt;</code>, see [[Time_element#impedance_match_new_date_time_inputs|impedance match new date time inputs]].<br />
* use cases in VCARDDAV & EDTF - see external links<br />
* [http://en.wikipedia.org/wiki/Template:Start_date Wikipedia 'Start date' template] - thousands of [http://bit.ly/aKhmdQ YYYY-MM instances]<br />
* Photo date taken<br />
** [http://laughingmeme.org/2011/06/02/flourishes-craftsmanship-dates-history-and-flickr/ Flickr supports year-month dates] - "Flickr taken dates come in 4 levels of granularity, exact, year-month, year, and circa."<br />
* Credit/ debit card expiry dates, entered into, then republished for verification on, e-commerce sites (security concerns prohibit use of example URL)<br />
* Restyling dates for localisation and to follow user conventions<br />
** 2010-08 to 08-2010 to 平22年8月 to 2010年8月 (all acceptable ways to represent August 2010 in Japan)<br />
* Relative dates in text: news websites, blogs and statistical institutes often use phrases like:<br />
** "in June 2010, the turnover […] decreased by 10.5% compared to the same month of the previous year." [http://www.nsi.bg/eventen.php?n=568]<br />
** "George W. Bush leaves office in January next year" [http://afp.google.com/article/ALeqM5hm2kKrBzl5p5Psm-EryzKK_m8H_A]<br />
<br />
=== year month discussion ===<br />
<div class="discussion"><br />
Opinions / discussion:<br />
* +1 [[Faruk]] (per [http://www.w3.org/Bugs/Public/show_bug.cgi?id=7145 Bug 7145 - Valid date strings should accept ambiguous inputs, like "2009" or "2007-01"]) One example is the very common archive view found on most blogs, which contain distinct links or headers for each year, each month per year, and often each date within a chosen or highlighted month. Currently, the <code>&lt;time&gt;</code> element only allows for <code>datetime</code> values as precise as a specific day, e.g. YYYY-MM-DD.<br />
* -1 [[Hixie]] - "Without clear use cases, I don't intend to change the spec here." (ibid)<br />
* +1 [[User:Tantek|Tantek]] I think the blog archives use case (where blogs often link to their archives by a specific month and year) is sufficient to justify adding this capability to the time element. Content hosting sites like Flickr also list archives by specific year/month, e.g. see http://www.flickr.com/photos/tantek/archives/<br />
* +1 [[User:Pigsonthewing|Andy Mabbett]] (Per use cases in VCARDDAV & EDTF - see external links)<br />
* +1 [[User:Philipj|Philip Jägenstedt]] - for marking up [http://musicbrainz.org/release/aa82c130-c734-4d9c-b06a-5bba9b44295d.html release dates on e.g. MusicBrainz] where the date is given as YYYY, YYYY-MM or YYYY-MM-DD.<br />
* +1 [[User:asbjornu|Asbjørn Ulsberg]] - for marking up [http://en.wikipedia.org/wiki/World_war_2#Japanese_invasion_of_China month+year on Wikipedia] ("In July 1937, Japan captured the former Chinese imperial capital of Beiping...").<br />
* +1 [[User:GlennJones|Glenn Jones]] - This is the most commonly used format date description for Resume's. Linked-in use it http://www.linkedin.com/in/steveganz and Stackoverflow http://careers.stackoverflow.com/klmr I could list many more cases in the wild.<br />
* +1 [[User:Oli|Oli Studholme]] As with the year example above, this would be useful for semantically marking up year-month dates, as in Japan there’s an additional era-based method of representing years (and even Japanese people find it difficult to convert between them), and it would allow the browser to automatically display the user-preferred format. It would also also enable browser-based localisation (adding a 年 after the year, and 月 after the month). Having this data semantically notated would help make the use in Japan of 2-digit years on credit cards and in e-commerce more accessible. Finally it would be useful for marking up future imprecise dates (e.g. events being planned), allowing someone to add these dates to a calendar automatically (rather than marking up teh events plus manually adding them to a calendar). [ref: [http://lists.whatwg.org/htdig.cgi/whatwg-whatwg.org/2010-August/028025.html email to WHATWG]]<br />
* +1 [[User:Ocolon|Martin Janecke]] - This would be great to mark up relative dates ("next January I will …") that actually refer to an absolute date in the context of the text and the publication date of the text respectively.<br />
* ...<br />
</div><br />
<br />
=== year month related posts ===<br />
Related posts (listed with quotes directly related to year-month) :<br />
* [http://pigsonthewing.org.uk/dates-and-coordinates-in-html5/ 2009-02-23 Dates and coordinates in HTML5] blog post by Andy Mabbett - <blockquote cite="http://pigsonthewing.org.uk/dates-and-coordinates-in-html5/">hCalendar microformats are already used to mark up imprecise dates (“June 1977″; “2009″). ISO8601 already supports them. Why not HTML5?</blockquote><br />
* [http://www.brucelawson.co.uk/2009/html-5-politics-and-me/ 2009-02-25 HTML 5, politics and me] blog post by Bruce Lawson - look for mention of "time element" which mentions: <blockquote cite="http://www.brucelawson.co.uk/2009/html-5-politics-and-me/">I see no reason why authors shouldn’t be able to mark up ... dates like “July 2008″ ... which are currently disallowed by the spec</blockquote><br />
* [http://www.brucelawson.co.uk/2009/marking-up-a-blog-with-html-5-part-2/#time 2009-03-06 Marking up a blog with HTML 5 (part 2) : Time] blog post by Bruce Lawson: <blockquote>I suggest the spec be amended to allow dates like "July 1966"</blockquote><br />
* [http://www.brucelawson.co.uk/2009/html-5-whats-hot-whats-not/ 2009-08-20 HTML 5: what’s hot, what’s not] blog post by Bruce Lawson - see section on TIME which explicitly mentions: <blockquote cite="http://www.brucelawson.co.uk/2009/html-5-whats-hot-whats-not/">The time element is still hamstrung by not being able to markup ... dates like “December 1935″</blockquote><br />
* [http://adactio.com/journal/1604/ 2009-08-30 HTML5 and me] blog post by Jeremy Keith - see section on "time" which explicitly mentions <blockquote cite="http://adactio.com/journal/1604/">make a piece of information like “April 1912” machine-readable</blockquote><br />
* [http://html5doctor.com/the-time-element/ 2010-02-09 The time element (and microformats)] blog post on HTML5 Doctor by Bruce Lawson - mentions: <blockquote>The only trouble with &lt;time&gt; is that the <nowiki>[sic]</nowiki> it must contain positive date on the Proleptic Gregorian calendar, meaning you can’t encode a date before the Christian Era. Neither can you encode imprecise dates such as “July 1904″.</blockquote><br />
<br />
=== year month next steps ===<br />
Per this edit/comment from Ian: http://lists.w3.org/Archives/Public/public-html-diffs/2010Aug/0234.html<br />
<br />
We need to help create a CSS feature for styling dates to local conventions (e.g. 2000-12-31 vs 31-12-2000 vs 12-31-2000 vs Japanese conventions for year and year-month). Once such a CSS feature exists, it will apparently provide additional weight for including year-month dates in the time element.<br />
<br />
== year week only ==<br />
;Status<br />
:[http://html5.org/tools/web-apps-tracker?from=6826&to=6827 2011-11-18] '''Adopted in WHATWG HTML.''' <br />
;Summary<br />
:The time element should accept just a year and a week number.<br />
;ISO8601 syntax<br />
:YYYY-WNN<br />
;use case research<br />
:no examples in the wild currently. If anyone knows of any sites which publish references to specific weeks of a year, either by name / expression (e.g. "first week of the year") or by specific number (e.g. "weeks 1-26"), please provide URLs and quotes of example content.<br />
:output equivalent of <code>&lt;input type="week"&gt;</code>, see [[Time_element#impedance_match_new_date_time_inputs|impedance match new date time inputs]] above.<br />
:OpenStreetMap's opening_hours tag allows specification of opening hours (of business, shops, parks etc.) by week number. See [http://www.openstreetmap.org/browse/way/40879988 example], [https://wiki.openstreetmap.org/wiki/Key:opening_hours documentation]<br />
<br />
;reasoning<br />
:to provide the output equivalent of <code>&lt;input type="week"&gt;</code><br />
<br />
See [[Time_element#impedance_match_new_date_time_inputs|impedance match new date time inputs]] above.<br />
<br />
<div class="discussion"><br />
Opinions / discussion:<br />
* +1 [[Tantek]] per good design of impedance matching date time inputs.<br />
* ...<br />
</div><br />
<br />
== month day only ==<br />
;Status<br />
:[http://html5.org/tools/web-apps-tracker?from=6826&to=6827 2011-11-18] '''Adopted in WHATWG HTML.''' <br />
;Summary<br />
:The time element should accept just a month and a day.<br />
;ISO8601 syntax<br />
:--MM-DD<br />
;use case research<br />
:http://microformats.org/wiki/birthday-examples#month_and_day_only<br />
:[http://www.ietf.org/mail-archive/web/vcarddav/current/msg00999.html use cases discussed in VCARDDAV] & EDTF - see external links<br />
:Facebook - allows users to elect to show their birthday as, for example, "17 December", with no year.<br />
<br />
<div class="discussion"><br />
Opinions / discussion:<br />
* +1 [[Tantek]] (per [http://www.zeldman.com/superfriends/guide/#time HTML5 Super Friends Technical Details: time element])<br />
* +1 "radiz" implied support for --MM-DD with the use case question: "How to use &lt;time&gt; with a date in astrology?" in the article http://html5doctor.com/your-questions-answered-6/<br />
* +1 [[User:Pigsonthewing|Andy Mabbett]] (Per [http://www.ietf.org/mail-archive/web/vcarddav/current/msg00999.html use cases discussed in VCARDDAV] & EDTF, e.g. birthdays, wedding anniversaries - see external links)<br />
** [http://portablecontacts.net/draft-spec.html#anchor16 Portable contacts allows this] using a "0000" year value.<br />
* ...<br />
</div><br />
== See Also ==<br />
* [[Time element]]</div>Tom Morris