Module:Parsedate/doc: Difference between revisions
Appearance
Content deleted Content added
create a short documentation |
→Examples: tidy |
||
Line 16: | Line 16: | ||
== Examples == |
== Examples == |
||
<code><nowiki>{{#invoke: |
<code><nowiki>{{#invoke: Parsedate | parse_date | 28 August 2013}}</nowiki></code> |
||
will produce |
will produce |
||
{{#invoke: |
{{#invoke: Parsedate | parse_date | 28 August 2013}} |
||
- inspect the html to see the microformat. |
- inspect the html to see the microformat. |
||
Latest revision as of 19:22, 11 January 2018
The module “Parsedate” contains one available calls that will accept an input string and return a string that:
- for a valid date, wraps a hidden copy of the date in ISO format in a microformat
- returns the input.
Usage
[edit]{{#invoke:Parsedate|parse_date|input_string}}
Parameters
[edit]- Positional parameter – the value of frame.args[1] is passed after function name and vertical bar and is the string to be parsed for a valid date.
Examples
[edit]{{#invoke: Parsedate | parse_date | 28 August 2013}}
will produce
28 August 2013 - inspect the html to see the microformat.There are several test cases at User:RexxS/DateDataTest which use extra code to illustrate the parsing.