编辑“︁
Template:Random portal component/doc
”︁
跳转到导航
跳转到搜索
这是
Random portal component
模板的
文档页面
。
警告:
您没有登录。如果您进行任何编辑,您的IP地址会公开展示。如果您
登录
或
创建账号
,您的编辑会以您的用户名署名,此外还有其他益处。
反垃圾检查。
不要
加入这个!
<includeonly><!-- 在這裡加入模板的保護標識 --></includeonly> <!-- 在本行下編輯模板說明 --> {{缺乏中文說明}} {{Documentation subpage}} {{lua|Module:Random portal component}} <!-- EDIT TEMPLATE DOCUMENTATION AFTER THIS LINE --> This template generates a box for a portal home page. The content is drawn randomly from a pre-defined list. == Layout == <pre> {{Random portal component |max = |template = |header = |footer = |subpage = |rootpage = |headertemplate = }} </pre> == Usage == * '''header''': (Optional) The header text of the box. If no header is passed to the template, the default is the subpage name. * '''footer''': (Optional) The footer text in the box. E.g. ''Nominations for selected picture''. * '''rootpage''': (Optional) The root of the transcluded page, e.g. ''Portal:Foo''. * '''subpage''': The subpage of the transcluded page, e.g. ''Selected picture''. * '''max''': The maximum number of sub-subpages. Must be a positive integer. * '''headertemplate''': (Optional) The name of the template to use for the box header, e.g. {{code|Box-header/10}} for [[Template:Box-header/10]]; default is the portal's {{code|/box-header}} subpage === Formatting subpages === * Create a sub-page first. If your portal is {{code|Portal:Foo}}, then a sub-page could be {{code|Portal:Foo/Selected bar}}. * On the {{code|Portal:Foo/Selected bar}} sub-page, place the template {{tl|numbered subpages}} on the page and save it. * Once the list of subject links have been created, use one of the {{code|Selected <subject>}} templates from below to format each of the subject sub-pages. * This template calls {{code|/box-header}} (if {{code|headertemplate}} is not specified) and {{tl|box-footer}} for its color styles and closing. Either {{code|headertemplate}} must be used, or the {{code|/box-header}} subpage must exist for everything to work correctly. == Example == To see a real time example, see [[Special:Whatlinkshere/Template:{{BASEPAGENAME}}&hidelinks=1|what links here]] (the list of pages that currently transclude the {{tl|{{BASEPAGENAME}}}} template). Here is a stale example of the output generated by this template. <pre> {{Box-header | title=Header |editpage = Template:Lorem ipsum |border = Black |titleforeground = #ffe247 |titlebackground = #646464 |background = #FFFFFF |foreground = black }} {{Lorem ipsum}} {{Box-footer | Footer }} </pre> will produce: {{Box-header | title=Header |editpage = Template:Lorem ipsum |border = Black |titleforeground = #ffe247 |titlebackground = #646464 |background = #FFFFFF |foreground = black}} {{Lorem ipsum}} {{Box-footer | Footer }} == See also == {{Portal template list}} <includeonly>{{Sandbox other|| <!--Categories below this line, please; interwikis at Wikidata--> [[Category:主題模板]] }}</includeonly>
摘要:
请注意,所有对Local Chinese Wikipedia的贡献均可能会被其他贡献者编辑、修改或删除。如果您不希望您的文字作品被随意编辑,请不要在此提交。
您同时也向我们承诺,您提交的内容为您自己所创作,或是复制自公共领域或类似自由来源(详情请见
Project:著作权
)。
未经许可,请勿提交受著作权保护的作品!
取消
编辑帮助
(在新窗口中打开)
导航菜单
个人工具
未登录
讨论
贡献
创建账号
登录
命名空间
模板
讨论
大陆简体
不转换
简体
繁體
大陆简体
香港繁體
澳門繁體
大马简体
新加坡简体
臺灣正體
查看
阅读
编辑
查看历史
更多
搜索
导航
首页
最近更改
随机页面
MediaWiki帮助
工具
链入页面
相关更改
特殊页面
页面信息