Difference between revisions of "Module:Birthday"
Jump to navigation
Jump to search
Line 9: | Line 9: | ||
local month = "" | local month = "" | ||
if (mw.ustring.find(date, "August") | if (mw.ustring.find(date, "August")) then | ||
month = "8" | month = "8" | ||
end | end |
Revision as of 13:25, 9 May 2021
Documentation for this module may be created at Module:Birthday/doc
local p = {} function p.main(frame) local titleObject = mw.title.getCurrentTitle() local titleText = titleObject.fullText local date = mw.ustring.gsub(titleText, "List of characters born on ", "") local month = "" if (mw.ustring.find(date, "August")) then month = "8" end local result = "This is a list of characters born on " .. date .. " --- test: " .. mw.ustring.find(date, "August") .. "test test" .. month .. "." local result = result .. "[[Category:Lists]]" local result = result .. "[[Category:Lists of characters by birthday]]" return result end return p