Jump to content

Template:Date

From Wikinews, the free news source you can write!
[edit] Template documentation

Purpose

The Date template is used on Wikinews articles to display the publication date and automatically add the article to the correct daily category, once published. It also embeds structured metadata (COinS) and a microformat for compatibility with bibliographic tools.

Usage

Enter the date as the only parameter of this template. For example:

  • {{date|April 23, 2026}}

Examples

{{date|December 25, 2024}}
Output

Wednesday, December 25, 2024

{{date|2024-12-25}}
Output

Wednesday, December 25, 2024

Behavior

  • In the main namespace:
    • Displays the formatted publication date in bold.
    • Adds the article to the correct daily category (e.g. [[Category:December 25, 2024]]).
    • Embeds COinS metadata and microformat markup.
  • If the article is still a draft (detected by Module:DetectDraft), the daily category is not added.
  • In all other namespaces, no category is added.

Microformat

The template outputs with class="published" and includes the date in ISO format using value-title. See hAtom for details.

Internals

  • Categories are generated using {{#time}} in the format [[Category:F j, Y]].
  • When called without a parameter, output falls back to {{date/none}}.
  • {{COinS}} is included to embed structured citation metadata.

See also

  • {{date/none}} – placeholder when no date is available.
  • {{COinS}} – embeds metadata for bibliographic tools.
  • Module:DetectDraft – detects draft templates in articles.