440
edits
(add args.page) |
m (1 revision imported from templatewiki:Module:Purge) |
||
(6 intermediate revisions by 4 users not shown) | |||
Line 11:
local url
do
local title
local title = args.page and mw.title.new(args.page) or mw.title.getCurrentTitle()▼
if args.page then
title = mw.title.new(args.page)
if not title then
error(string.format(
"'%s' is not a valid page name",
args.page
), 2)
end
else
end
if args.anchor then
title.fragment = args.anchor
Line 19 ⟶ 30:
-- Make the display
local display
if args.page then
display▼
else
:wikitext(args[1] or 'Purge')▼
:attr('title', 'Purge this page')
▲ :wikitext(args[1] or 'Purge')
display = tostring(display)
end
-- Output the HTML
|