Template:Roman Year/doc

From Imperivm Romanvm
< Template:Roman Year
Revision as of 21:30, 10 June 2022 by Procurator-Imperii-Romani (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
  • 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

{{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

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

  • If 0 is entered an error occurs, an if statement or check would solve this. This bug is shared with {{Roman Date}}

Example

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

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.

Template parameters

ParameterDescriptionTypeStatus
Year1

The Year to be converted to Ab Urbe Condita. If the year cannot be processed, nothing will be returned.

Example
2022
Numberoptional

See also