Template:Roman Year/doc: Difference between revisions
Jump to navigation
Jump to search
(Created page with "{{Documentation subpage}} {{Lua|Module:Roman Year}} {{Lua sidebar}} * This module supports years in both CE and BCE, but with caveats. * This is a new module and may be subject to bugs, to report bugs please use the discord == Usage == {{pre|<nowiki>{{Roman Year|</nowiki>''YYYY''<nowiki>}}</nowiki>}} Replace <code>''YYYY''</code> with the year you would like to be converted to Ab Urbe Condita. When giving a year in BCE, pass the year with a minus sign in front of...") |
No edit summary |
||
Line 15: | Line 15: | ||
== Examples == | == Examples == | ||
{|class="wikitable" style="text-align:center" | {|class="wikitable" style="text-align:center" | ||
! BCE/CE !! Template call !! | ! BCE/CE !! Template call !! Ab Urbe Condita | ||
|- | |- | ||
|27 BCE|| <nowiki>{{Roman Year|-27}}</nowiki> || {{Roman | |27 BCE|| <nowiki>{{Roman Year|-27}}</nowiki> || {{Roman Year|-27}} | ||
|- | |- | ||
|23 BCE|| <nowiki>{{Roman Year|-23}}</nowiki> || {{Roman | |23 BCE|| <nowiki>{{Roman Year|-23}}</nowiki> || {{Roman Year|-23}} | ||
|- | |- | ||
|1 CE|| <nowiki>{{Roman Year|1}}</nowiki> || {{Roman | |1 CE|| <nowiki>{{Roman Year|1}}</nowiki> || {{Roman Year|1}} | ||
|- | |- | ||
|1 BCE|| <nowiki>{{Roman Year|-1}}</nowiki> || {{Roman | |1 BCE|| <nowiki>{{Roman Year|-1}}</nowiki> || {{Roman Year|-1}} | ||
|- | |- | ||
|01 CE || <nowiki>{{Roman Year|01}}</nowiki> || {{Roman | |01 CE || <nowiki>{{Roman Year|01}}</nowiki> || {{Roman Year|01}} | ||
|- | |- | ||
|02 CE || <nowiki>{{Roman Year|02}}</nowiki> || {{Roman | |02 CE || <nowiki>{{Roman Year|02}}</nowiki> || {{Roman Year|02}} | ||
|- | |- | ||
|2012 CE || <nowiki>{{Roman Year|2012}}</nowiki> || {{Roman | |2012 CE || <nowiki>{{Roman Year|2012}}</nowiki> || {{Roman Year|2012}} | ||
|- | |- | ||
|2024 CE || <nowiki>{{Roman Year|2024}}</nowiki> || {{Roman | |2024 CE || <nowiki>{{Roman Year|2024}}</nowiki> || {{Roman Year|2024}} | ||
|- | |- | ||
|2000 CE || <nowiki>{{Roman Year|2000}}</nowiki> || {{Roman | |2000 CE || <nowiki>{{Roman Year|2000}}</nowiki> || {{Roman Year|2000}} | ||
|- | |- | ||
|2022 CE || <nowiki>{{Roman Year|2022}}</nowiki> || {{Roman | |2022 CE || <nowiki>{{Roman Year|2022}}</nowiki> || {{Roman Year|2022}} | ||
|- | |- | ||
|75 BCE || <nowiki>{{Roman Year|-75}}</nowiki> || {{Roman | |75 BCE || <nowiki>{{Roman Year|-75}}</nowiki> || {{Roman Year|-75}} | ||
|- | |- | ||
|2016 CE || <nowiki>{{Roman Year|2016}}</nowiki> || {{Roman | |2016 CE || <nowiki>{{Roman Year|2016}}</nowiki> || {{Roman Year|2016}} | ||
|- | |- | ||
|2017 CE || <nowiki>{{Roman Year|2017}}</nowiki> || {{Roman | |2017 CE || <nowiki>{{Roman Year|2017}}</nowiki> || {{Roman Year|2017}} | ||
|- | |- | ||
|2001 CE || <nowiki>{{Roman Year|2001}}</nowiki> || {{Roman | |2001 CE || <nowiki>{{Roman Year|2001}}</nowiki> || {{Roman Year|2001}} | ||
|- | |- | ||
|{{CURRENTYEAR}} CE || <nowiki>{{Roman Year|</nowiki>{{CURRENTYEAR}}<nowiki>}}</nowiki> || {{Roman Year|{{CURRENTYEAR}}}} | |{{CURRENTYEAR}} CE || <nowiki>{{Roman Year|</nowiki>{{CURRENTYEAR}}<nowiki>}}</nowiki> || {{Roman Year|{{CURRENTYEAR}}}} | ||
Line 49: | Line 49: | ||
==Known Bugs== | ==Known Bugs== | ||
* | * If 0 is entered an error occurs, an if statement or check would solve this. This bug is shared with {{tl|Roman Date}} | ||
=== Example === | |||
{|class="wikitable" style="text-align:center" | |||
! BCE/CE !! Template call !! Ab Urbe Condita | |||
|- | |||
|0 CE|| <nowiki>{{Roman Year|0}}</nowiki> || {{Roman Year|0}} | |||
|- | |||
|0 BCE|| <nowiki>{{Roman Year|-0}}</nowiki> || {{Roman Year|-0}} | |||
|} | |||
==TemplateData== | ==TemplateData== | ||
{{TemplateDataHeader}} | {{TemplateDataHeader}} |
Latest revision as of 21:30, 10 June 2022
This is a documentation subpage for Template:Roman Year. It contains usage information, categories and other content that is not part of the original template page. |
This template uses Lua: |
Related pages |
---|
- This module supports years in both CE and BCE, but with caveats.
- This is a new module and may be subject to bugs, to report bugs please use the discord
Usage[edit source]
{{Roman Year|YYYY}}
Replace YYYY
with the year you would like to be converted to Ab Urbe Condita. When giving a year in BCE, pass the year with a minus sign in front of the year with no space (753 BCE => -753).
For more information please see Roman Dates.
Examples[edit source]
BCE/CE | Template call | Ab Urbe Condita |
---|---|---|
27 BCE | {{Roman Year|-27}} | DCCXXVII AVC |
23 BCE | {{Roman Year|-23}} | DCCXXXI AVC |
1 CE | {{Roman Year|1}} | DCCLIV AVC |
1 BCE | {{Roman Year|-1}} | DCCLIII AVC |
01 CE | {{Roman Year|01}} | DCCLIV AVC |
02 CE | {{Roman Year|02}} | DCCLV AVC |
2012 CE | {{Roman Year|2012}} | MMDCCLXV AVC |
2024 CE | {{Roman Year|2024}} | MMDCCLXXVII AVC |
2000 CE | {{Roman Year|2000}} | MMDCCLIII AVC |
2022 CE | {{Roman Year|2022}} | MMDCCLXXV AVC |
75 BCE | {{Roman Year|-75}} | DCLXXIX AVC |
2016 CE | {{Roman Year|2016}} | MMDCCLXIX AVC |
2017 CE | {{Roman Year|2017}} | MMDCCLXX AVC |
2001 CE | {{Roman Year|2001}} | MMDCCLIV AVC |
2024 CE | {{Roman Year|2024}} | MMDCCLXXVII AVC |
Known Bugs[edit source]
- If 0 is entered an error occurs, an if statement or check would solve this. This bug is shared with {{Roman Date}}
Example[edit source]
BCE/CE | Template call | Ab Urbe Condita |
---|---|---|
0 CE | {{Roman Year|0}} | Lua error in Module:Roman_Year at line 15: attempt to perform arithmetic on global 'avc' (a nil value). |
0 BCE | {{Roman Year|-0}} | Lua error in Module:Roman_Year at line 15: attempt to perform arithmetic on global 'avc' (a nil value). |
TemplateData[edit source]
This is the TemplateData for this template used by TemplateWizard, VisualEditor and other tools. Click here to see a monthly parameter usage report for this template based on this TemplateData.
TemplateData for Roman Year
Convert years to Ab Urbe Condita.
Parameter | Description | Type | Status | |
---|---|---|---|---|
Year | 1 | The Year to be converted to Ab Urbe Condita. If the year cannot be processed, nothing will be returned.
| Number | optional |
See also[edit source]
- {{Roman Numeral}}
- {{Roman Date}}
- Roman Dates