Template:Date sum

From Meta Wiki
Jump to: navigation, search

30 September 2020

Documentation icon.png Template documentation[edit] [purge]
This documentation is transcluded from Template:Date sum/doc.

{{Date sum|date|time to be added to the date}}

Returns a future time based on the input date and the time to be added to it. Accepted input date formats are the same as for #time parser function.

Data

Show/hide template's data

The following information is used by extensions and applications, such as VisualEditor, to help users implement this template onto pages. Please ensure that it is up-to-date.

No description.

Template parameters

This template has custom formatting.

ParameterDescriptionTypeStatus
Date1

Input date.

Default
now
Example
10-8-2012
Auto value
empty
Dateoptional
Time2

Time to be added to the date.

Default
1 week
Example
2 weeks 4 days 3 hours
Auto value
empty
Stringoptional
Formatformat

Format used to display the date.

Default
d F Y
Example
Y-m-d
Auto value
empty
Stringoptional

Example

{| class="wikitable sortable"
!Date
|-
| {{Date sum|1/10/2012|2 weeks}} 1/10/2012}}
|-
| {{Date sum|4-8-2012|2 weeks 4 days|format=d F Y}}
|-
| {{Date sum|20 December 2000|2 weeks 4 days 3 minutes 1 second|format=d F Y H:i:s}}
|}
Date
24 January 2012
22 August 2012
07 January 2001 00:03:01