Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Humanipedia
Search
Search
Appearance
Create account
Log in
Personal tools
Create account
Log in
Pages for logged out editors
learn more
Contributions
Talk
Editing
Module:Year in various calendars/doc
(section)
Module
Discussion
English
Read
Edit source
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit source
View history
General
What links here
Related changes
Special pages
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
=== Adding new calendars === The module is set up to allow for easy addition of new calendars. Just scroll down to the "Build the box" section of the module code, and add your calendar as follows: To display one year: <div style="overflow: auto;"><syntaxhighlight lang="lua"> local myCalendar = calendar:new() myCalendar:setLink( 'My calendar article' ) -- The name of the calendar's Wikipedia article. myCalendar:setYear( year + 10 ) -- Lua code linking the Gregorian calendar year to your calendar's year. box:addCalendar( myCalendar ) </syntaxhighlight></div> To display a year range: <div style="overflow: auto;"><syntaxhighlight lang="lua"> local myCalendar = calendar:new() myCalendar:setLink( 'My calendar article' ) -- The name of the calendar's Wikipedia article. myCalendar:setYearRange( year + 10, year + 11 ) -- Lua code outputting the start year and the end year of the year range. box:addCalendar( myCalendar ) </syntaxhighlight></div> More complicated calendars can be passed as a string to <code>calendar:setYear()</code>.
Summary:
Please note that all contributions to Humanipedia may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
Humanipedia:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)