檢視 模块:Error 的原始碼
由於下列原因,您沒有權限進行 編輯此頁面 的動作:
您可以檢視並複製此頁面的原始碼。
-- This module implements {{error}}.
local p = {}
local function _error(args)
local message = args.message or args[1] or error('没有指定的-{zh-cn:信息; zh-tw:資訊}-', 2)
message = tostring(message)
local tag = mw.ustring.lower(tostring(args.tag))
-- Work out what html tag we should use.
if not (tag == 'p' or tag == 'span' or tag == 'div') then
tag = 'strong'
end
-- Generate the html.
local root = mw.html.create(tag)
root
:addClass('error')
:wikitext(message)
return tostring(root)
000
1:0
此頁面使用了以下模板:
返回「模块:Error」頁面