模块:沙盒
跳到导航
跳到搜索
可在模块:沙盒/doc创建此模块的帮助文档
local getArgs = require('Module:Arguments').getArgs
local p = {}
function p._greet(who)
if not who or who == "" then
who = "world"
end
return "Hello, " .. who .. "!"
end
function p.greet(frame)
local args = getArgs(frame)
return p._greet(args[1])
end
function p.args_test(frame)
local args = getArgs(frame)
return mw.dumpObject(args)
end
function p.args_test_orig(frame)
local args = getArgs(frame, { trim=false, removeBlanks=false })
return mw.dumpObject(args)
end
return p