Template talk:Date

Latest comment: 2 months ago by Michael.C.Wright in topic Update to functionality

Documentation

edit

The date is the only parameter of this template. Technically it can be entered in any format accepted by #time, i.e. php data format. For example:

  • {{date|April 12, 2009}}}} gives Sunday, April 12, 2009
  • {{date|apr12,9}}}} gives Sunday, April 12, 2009
  • {{date|4/12/9}}}} gives Sunday, April 12, 2009
  • {{date|12 April 2009}}}} gives Sunday, April 12, 2009
  • {{date|12apr9}}}} gives Sunday, April 12, 2009
  • {{date|12-4-2009}}}} gives Sunday, April 12, 2009
  • {{date|9-4-12}}}} gives Sunday, April 12, 2009
  • {{date|20090412}}}} gives Sunday, April 12, 2009

The blank lines "problem"

edit

I've noticed that Dan100 has changed the template so that there is no more blank line between the date and the article content. While this was perceived to be a problem, I in fact found it to be very useful. Now the date appears squashed in at the top, with no separation to the article text, and doesn't look very good. For example, see the article TAROM cancels all Bucharest-Arad flights. What do other people think? Do others prefer to change it back to how it was with the added line break? Ronline 08:46, 13 Apr 2005 (UTC)

Look at the date of that edit in the History. I made that change two months ago! I don't know why the page rendering has suddenly changed now. I'll rv to before my edit and see what the effect is. Dan100 (Talk) 08:41, 14 Apr 2005 (UTC)

Interwikis

edit

Please add the following interwikis:

<noinclude>
[[ca:Plantilla:Crèdit]]
[[de:Vorlage:Veröffentlicht]]
[[es:Plantilla:Fecha]]
[[fr:Modèle:Date]]
[[he:תבנית:תאריך]]
[[it:Template:Data]]
[[ja:Template:日付]]
[[nl:Sjabloon:Datum]]
[[no:Mal:Artikkel]]
[[pl:Szablon:Data]]
[[pt:Predefinição:Data]]
[[ro:Format:Dată]]
[[sv:Mall:Datum]]
[[zh:Template:Date]]</noinclude>

. Thanks - Jurock (reply here) 23:00, 18 October 2007 (UTC)Reply

Please use <noinclude></noinclude> tags. Sp5uhe 10:29, 19 October 2007 (UTC)Reply

  Done DragonFire1024 (Talk to the Dragon) 21:41, 22 October 2007 (UTC)Reply
It's causing greaaat problem... Remember to put the <noinclude> tag just after the last character of the template, like this:
{{#if:{{{nocat|}}}||[[Category:{{{1}}}]]}}
'''{{{1}}}'''<noinclude>

[[ca:Plantilla:Crèdit]]
[[de:Vorlage:Veröffentlicht]]
[[es:Plantilla:Fecha]]
[[fr:Modèle:Date]]
[[he:תבנית:תאריך]]
[[it:Template:Data]]
[[ja:Template:日付]]
[[nl:Sjabloon:Datum]]
[[no:Mal:Artikkel]]
[[pl:Szablon:Data]]
[[pt:Predefinição:Data]]
[[ro:Format:Dată]]
[[sv:Mall:Datum]]
[[zh:Template:Date]]</noinclude>

Jurock (reply) 00:11, 23 October 2007 (UTC)Reply

  Done irid t i e 00:15, 23 October 2007 (UTC)Reply
  Done A HA! That's what was causing it. I nearly broke a blood vessel in IRC earlier :) —The preceding unsigned comment was added by DragonFire1024 (talkcontribs)

Update to functionality

edit

In the Template:Date/sandbox, I have added the ability for this template to detect if the article is a draft article. If the article is a draft, the template does not add the article to a date category. Our date categories are reserved for published articles only and EasyPeerReview will possibly change the date and thus the date category when the article is published.

After testing using {{Date/sandbox|February 28, 2025}} or similar, please copy the code from the sandbox to the template to incorporate the change. Thank you in advance. —Michael.C.Wright (Talk/Reviewer) 18:13, 28 February 2025 (UTC)Reply

Once the change is incorporated, I will update the documentation. —Michael.C.Wright (Talk/Reviewer) 18:18, 28 February 2025 (UTC)Reply
Why is this needed? I've been using the 'date' template for several years without any issues. I don't think 'draft being in a date category' is an issue, as all 'published articles' feeds are already utilizing the intersection of 'date xyz' and 'published' categories, anyway. Gryllida (talk) 21:43, 31 March 2025 (UTC)Reply
If someone clicks on a date category of a published article, they will also see articles that are in that date category but marked for speedy deletion, copyvio, or otherwise disputed. This is undesirable. We want readers to go from quality, published article to quality, published article.
Category:March 31, 2025 provides a good example of this undesirable behavior. Only one article has been published today. The other three articles in that category are in various degrees of draft and quality.
Also, before an article is published, the date it is published is useless (or even misleading) and likely to be changed by EasyPeerReview, unless the article was drafted, reviewed, and published all on the same day. —Michael.C.Wright (Talk/Reviewer) 23:30, 31 March 2025 (UTC)Reply
Return to "Date" page.