Difference between revisions of "Wiki tweak page"

Marked this version for translation
m (added languages and translate tags)
(Marked this version for translation)
 
Line 2: Line 2:
__TOC__
__TOC__
<translate>
<translate>
== How to create templates ==
== How to create templates == <!--T:1-->
{{BoxWarning|If you feel a template is missing or needs improvement?|Use this [[Talk:Wiki_tweak_page|Discussion link]] and discuss the change with your fellow editors.
{{BoxWarning|If you feel a template is missing or needs improvement?|Use this [[Talk:Wiki_tweak_page|Discussion link]] and discuss the change with your fellow editors.
<p>Before creating new templates the existing [[Help:Template|Template collection]] and preferably use one of them.</p>}}
<p>Before creating new templates the existing [[Help:Template|Template collection]] and preferably use one of them.</p>}}
Line 8: Line 8:
  Example: <nowiki>http://wiki.manjaro.org/index.php/Template:TemplateNameBase</nowiki>
  Example: <nowiki>http://wiki.manjaro.org/index.php/Template:TemplateNameBase</nowiki>


<!--T:2-->
After creating the page, edit it by taking the code below as example
After creating the page, edit it by taking the code below as example
<pre><noinclude>{{Template}}</noinclude>
<pre><noinclude>{{Template}}</noinclude>
<includeonly>{{Box|{{{1}}}|{{{2}}}|#rgb|#rgb}}</includeonly></pre>
<includeonly>{{Box|{{{1}}}|{{{2}}}|#rgb|#rgb}}</includeonly></pre>


<!--T:3-->
Template arguments explained
Template arguments explained


<!--T:4-->
- rgb is the hex code for the border's color.
- rgb is the hex code for the border's color.
- rgb is the hex code for the background color.
- rgb is the hex code for the background color.
- Box is the template where these templates take their formatting.
- Box is the template where these templates take their formatting.


<!--T:5-->
Save your Template Base page and create a new page.
Save your Template Base page and create a new page.
  Example: <nowiki>http://wiki.manjaro.org/index.php/Template:TemplateName</nowiki>
  Example: <nowiki>http://wiki.manjaro.org/index.php/Template:TemplateName</nowiki>


<!--T:6-->
After creating the page, edit it and use below code as example
After creating the page, edit it and use below code as example
<pre><noinclude>{{Template}}</noinclude>
<pre><noinclude>{{Template}}</noinclude>
<includeonly>{{TemplateNameBase|TemplateName:|{{{1|{{Purpose}}}}}}}</includeonly></pre>
<includeonly>{{TemplateNameBase|TemplateName:|{{{1|{{Purpose}}}}}}}</includeonly></pre>


<!--T:7-->
Always preview your changes and fix bugs before you finally save the new template
Always preview your changes and fix bugs before you finally save the new template


===Usage===
===Usage=== <!--T:8-->
<nowiki>{{TemplateName|Text here}}</nowiki>
<nowiki>{{TemplateName|Text here}}</nowiki>
</translate>
</translate>
[[Category:Contents Page{{#translation:}}]]
[[Category:Contents Page{{#translation:}}]]