Jump to content

Module:Sandbox/CanonNi

From Wikipedia, the free encyclopedia
This is an old revision of this page, as edited by CanonNi (talk | contribs) at 07:10, 2 November 2024 (ugly but works). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.
local Date = require('Module:Date')._Date
local current = require('Module:Date')._current

local p = {}

function p.main(frame)
	if frame.args[1] ~= nil then
		local day = Date(frame.args[1]):text('dmy')
	else
		local day = Date(current.year, current.month, current.day):text('dmy')
	end
	
	return ": ''As of " .. day .. (frame.args[2] or '')
end

return p