切换搜索
搜索
切换菜单
notifications
切换个人菜单
查看“模块:For”的源代码
来自星际公民中文百科
查看
阅读
查看源代码
查看历史
associated-pages
模块
讨论
更多操作
←
模块:For
因为以下原因,您没有权限编辑本页:
您请求的操作仅限属于该用户组的用户执行:确认用户
您可以查看和复制此页面的源代码。
local mArguments --initialize lazily local mHatlist = require('Module:Hatnote list') local mHatnote = require('Module:Hatnote') local yesNo = require('Module:Yesno') local p = {} --Implements {{For}} from the frame --uses capitalized "For" to avoid collision with Lua reserved word "for" function p.For (frame) mArguments = require('Module:Arguments') return p._For(mArguments.getArgs(frame)) end --Implements {{For}} but takes a manual arguments table function p._For (args) local use = args[1] if (not use) then return mHatnote.makeWikitextError( 'no context parameter provided. Use {{other uses}} for "other uses" hatnotes.', 'Template:For#Errors', args.category ) end local pages = {} function two (a, b) return a, b, 1 end --lets us run ipairs from 2 for k, v in two(ipairs(args)) do table.insert(pages, v) end return mHatnote._hatnote( mHatlist.forSeeTableToString({{use = use, pages = pages}}), {selfref = args.selfref} ) .. ( (use == 'other uses') and yesNo(args.category) and '[[Category:Hatnote templates using unusual parameters]]' or '' ) end return p
本页使用的模板:
模板:Documentation
(
查看源代码
)
模板:Documentation/styles.css
(
查看源代码
)
模板:Hatnote/styles.css
(
查看源代码
)
模板:Mbox/styles.css
(
查看源代码
)
模板:Tl
(
查看源代码
)
模板:Wikipedia template
(
查看源代码
)
模块:DPLlua
(
查看源代码
)
模块:DependencyList
(
查看源代码
)
模块:Documentation
(
查看源代码
)
模块:Enum
(
查看源代码
)
模块:For/doc
(
查看源代码
)
模块:Paramtest
(
查看源代码
)
模块:Yesno
(
查看源代码
)
返回
模块:For
。
Debug data: