跳转到内容

模組:Al

被永久保护的模块
维基百科,自由的百科全书

这是本页的一个历史版本,由Xiplus留言 | 贡献2019年10月6日 (日) 05:52 建立内容为“local p = {} function p.main(frame) local args = frame:getParent().args return p._main(args) end function p._main(args) local ret = {} for i,…”的新页面)编辑。这可能和当前版本存在着巨大的差异。

(差异) ←上一修订 | 最后版本 (差异) | 下一修订→ (差异)
local p = {}

function p.main(frame)
	local args = frame:getParent().args
	return p._main(args)
end

function p._main(args)
	local ret = {}
	for i, title in ipairs(args) do
		ret[#ret + 1] = string.format('<span id="%s">[[:%s]]</span>', mw.language.getContentLanguage():ucfirst(title), title)
	end
	ret = mw.text.listToText(ret, '、', '、')
	return ret
end

return p