Jump to content

Module:High-use: Difference between revisions

added bot comment sandbox changes based on talk page discussion
m (1 revision imported)
(added bot comment sandbox changes based on talk page discussion)
Line 55: Line 55:


function p.text(frame, count)
function p.text(frame, count)
local bot_text = "\n\n----\nTransclusion count updated by [[User:Ahechtbot|Ahechtbot]]."
if frame.args["nobot"] == true then
bot_text = ""
end
if count == nil then count = _fetch(frame) end
if count == nil then count = _fetch(frame) end
local return_value = {}
local return_value = {}
Line 63: Line 68:
end
end
local templatecount = string.format("https://tools.wmflabs.org/templatecount/index.php?lang=en&namespace=%s&name=%s",mw.title.getCurrentTitle().namespace,mw.uri.encode(title.text))
local templatecount = string.format("https://templatecount.toolforge.org/index.php?lang=en&namespace=%s&name=%s",mw.title.getCurrentTitle().namespace,mw.uri.encode(title.text))
local used_on_text = string.format("'''This %s is used on [%s %s pages]'''",
local used_on_text = string.format("'''This %s is used on [%s %s pages]'''",
Line 98: Line 103:
end
end
return table.concat({used_on_text, sandbox_text, discussion_text, " before implementing them."})
return table.concat({used_on_text, sandbox_text, discussion_text, " before implementing them.", bot_text})
end
end


Anonymous user