模板:Documentation:修订间差异
外观
bwiki>43881503 小 已保护“模板:Documentation”([编辑=仅允许管理员](无限期)[移动=仅允许管理员](无限期)) |
wiki>月海伦娜 小 已从warcraft:模板:Documentation导入1个版本:interwiki import |
||
| 第1行: | 第1行: | ||
<div class=" | <div class="" style="padding:0px 1px;clear: both;"><div class="darken" style="padding:0.5em 0.5em 0.5em 1em;">'''模板文档''' <span style="font-size: 85%;">(本页面所展示的模板范例,有时会无法出现。) [[h:Help:模板|<span class="btn btn-primary">什么是模板?</span>]]</span> [{{fullurl:{{FULLPAGENAME}}/doc|action=edit}} <span class="btn btn-primary">编辑]</span> [{{fullurl:{{FULLPAGENAME}}|action=purge}} <span class="btn btn-primary"><span title="Refresh this page">刷新</span></span>]</div> <div class="" style="background:rgba(224, 223, 223, 0.16);padding: 1em; margin: 0.5em 0;">{{ | ||
#if: {{{content|}}} | |||
| <nowiki/> | |||
{{{content}}} | |||
| 关于本模板: | |||
{{ | |||
#ifexist: {{ #if: {{{1|}}} | {{{1}}} | {{FULLPAGENAME}}/doc }} | |||
|{{{{ | |||
|{{#ifexist: {{{1|{{ | #ifeq: {{NAMESPACE}} | {{ns:Template}} | ||
|| :{{NAMESPACE:{{ #if: {{{1|}}} | {{{1}}} | {{FULLPAGENAME}} }}}}: | |||
}}{{ #if: {{{1|}}} | {{PAGENAME:{{{1}}}}} | {{PAGENAME}}/doc}} }} | |||
}} [[ | | :<strong class="error">这个模板暂时没有说明文档。</strong>你可以[{{fullurl:{{ #if: {{{1|}}} | {{ urlencode: {{{1}}} }} | {{FULLPAGENAMEE}}/doc }}|action=edit&preload=Template:Documentation/preload}} 创建模板文档]。{{ | ||
#ifeq: {{NAMESPACE}} | {{ns:10}} | |||
| 在 [[h:templatemanager:{{ #if: {{{1|}}} | {{{1}}} | {{FULLPAGENAME}}/doc }}|灰机模板仓库]] 上面有大量可以复制的现成模板。 }}[[Category:Templates without documentation|{{PAGENAME}}]] | |||
}} | |||
}} </div> <div class="darken" style="clear: both; padding: 0.5em; margin: 0.5em 0; font-size: 85%; text-align: right;">{{ | |||
#if: {{{content|}}} | |||
| [{{fullurl:{{FULLPAGENAMEE}}|action=edit}} Edit this page] | |||
| 进入 {{ | |||
#ifexist: {{ #if: {{{1|}}} | {{{1}}} | {{FULLPAGENAME}}/doc }} | |||
| [[{{ #if: {{{1|}}} | {{{1}}} | {{FULLPAGENAME}}/doc }}]] | |||
{{#if:{{{ | | [{{fullurl:{{ #if: {{{1|}}} | {{ urlencode: {{{1}}} }} | {{FULLPAGENAMEE}}/doc }}|action=edit&preload=Template:Documentation/preload}} {{ #if: {{{1|}}} | {{{1}}} | {{FULLPAGENAME}}/doc }}] | ||
</div> | }}}} 页面来编辑这个模板的说明文档。([[Template:Documentation|这个说明框是怎么回事]]?)<br />修改完毕后,请[{{fullurl:{{FULLPAGENAME}}|action=purge}} 刷新]上面的文本。([[h:帮助:Huiji缓存|为什么?]])</div></div><noinclude>{{优质模板|功能}}[[Category:已经本地化的模板]][[Category:huiji template]]</noinclude> | ||
<noinclude>[[Category: | |||
2024年10月29日 (二) 12:02的版本
关于本模板:
| Lua标志 | 使用Lua |
| 文件:OOjs UI icon notice-warning.svg | Changes to it can cause immediate changes to the MediaWiki user interface. To avoid large-scale disruption, any changes should first be tested in this 模板's /sandbox or /testcases subpage, or in your own user space. Please discuss any changes on the talk page before implementing them. |
Usage
Customizing display
Overrides exist to customize the output in special cases:
- {{documentation|heading=}}: change the text of the "documentation" heading. If this is set to blank, the entire heading line (including the first [edit] link) will also disappear.
Rationale
This template allows any page to use any documentation page, and makes it possible to protect templates while allowing anyone to edit the template's documentation, categories, and interwiki links. It also reduces server resources by circumventing a technical limitation of templates (see a developer's explanation).
See also
This template allows to generate the documentation part of a given template.
| 参数 | 描述 | 类型 | 状态 | |
|---|---|---|---|---|
| content | content | defines the body of the documentation part | 字符串 | 可选 |
| heading | heading | allows to customise the header of the documentation part | 字符串 | 可选 |