Difference between revisions of "Template:Rules"

From xat wiki
Jump to: navigation, search
m
(using parser functions, no need for r attributes nor for other disabling attributes anymore; switching from table layout to containers)
Line 1: Line 1:
<includeonly>
+
<noinclude>
{| style="width:100%"
+
Attributes:
|style="font-weight:bold; text-align:center"|{{{header}}}
+
* '''header''' - add important message at the very top of the rules
|-
+
* '''header2''' - adds message right after with underline attribute (optional)
|style="text-decoration: underline; font-weight: bold; text-align: center; padding-bottom: 25px"|{{{header2|ALL RULES APPLY TO YOUR MESSAGES, NAME, STATUS, HOMEPAGE, AVATAR, ETC.}}}
+
* '''languages''' - value '''yes''', if rules are translatable
{{{r1|{{!-}}
+
* '''rules''' - list of rules (optional, '''see below for rule spoilers''')
{{!}}{{(!}} class="mw-collapsible mw-collapsed"
+
* '''staff''' - notes to staff members (optional)
! style="text-align:left" {{!}} 1. {{{rule1}}}&nbsp;
+
* '''extra''' - something extra that needs mentioning, see [[Trade Chat]] for example (optional)
{{!-}}
+
Having the staff attribute not included might be what you're after, if you have rules that are not in english. Information about staff can in that situation be included under attribute '''extra''' (see [[Rules:Fundos]] for an example).
{{!}}{{{rule1d}}}
+
----
{{!)}}}}}<!--
+
'''Optional''': If you wish, you could have your rules expand to save space (see [[Rules:Help]] for an example)
 +
 
 +
Attributes:
 +
*'''rule#''' - Short introduction of a rule
 +
*'''rule#d''' - More detailed version of a rule
 +
 
 +
Example:
 +
*'''|rule='''No profanity.
 +
*'''|ruled='''Now here I explain in '''d'''etail what words and situations apply to this rule.
 +
</noinclude><includeonly>
 +
<div style="width:100%"><!--
 +
 
 +
--><div style="font-weight:bold; text-align:center; padding-bottom: 8px; margin: 0 auto; width: 70%">{{{header}}}</div><!--
 +
 
 +
--><div style="text-decoration: underline; font-weight: bold; text-align: center; padding-bottom: 25px; margin: 0 auto; width: 70%">{{{header2|ALL RULES APPLY TO YOUR MESSAGES, NAME, STATUS, HOMEPAGE, AVATAR, ETC.}}}</div><!--
 +
 
 +
-->{{#ifeq:{{{languages}}}|yes|<div style="text-align:left; padding-bottom:25px"><languages/></div>|}}<!--
 +
 
 +
-->{{#if:{{{rule1|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">1. {{{rule1}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule1d}}}</div></div><div style="clear:both"></div>|}}<!--
 +
 
 +
-->{{#if:{{{rule2|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">2. {{{rule2}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule2d}}}</div></div><div style="clear:both"></div>|}}<!--
 +
 
 +
-->{{#if:{{{rule3|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">3. {{{rule3}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule3d}}}</div></div><div style="clear:both"></div>|}}<!--
  
-->{{{r2|
+
-->{{#if:{{{rule4|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">4. {{{rule4}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule4d}}}</div></div><div style="clear:both"></div>|}}<!--
{{(!}} class="mw-collapsible mw-collapsed"  
 
! style="text-align:left" {{!}} 2. {{{rule2}}}&nbsp;
 
{{!-}}
 
{{!}}{{{rule2d}}}
 
{{!)}}}}}<!--
 
  
-->{{{r3|
+
-->{{#if:{{{rule5|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">5. {{{rule5}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule5d}}}</div></div><div style="clear:both"></div>|}}<!--
{{(!}} class="mw-collapsible mw-collapsed"  
 
! style="text-align:left" {{!}} 3. {{{rule3}}}&nbsp;
 
{{!-}}
 
{{!}}{{{rule3d}}}
 
{{!)}}}}}<!--
 
  
-->{{{r4|
+
-->{{#if:{{{rule6|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">6. {{{rule6}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule6d}}}</div></div><div style="clear:both"></div>|}}<!--
{{(!}} class="mw-collapsible mw-collapsed"  
 
! style="text-align:left" {{!}} 4. {{{rule4}}}&nbsp;
 
{{!-}}
 
{{!}}{{{rule4d}}}
 
{{!)}}}}}<!--
 
  
-->{{{r5|
+
-->{{#if:{{{rule7|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">7. {{{rule7}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule7d}}}</div></div><div style="clear:both"></div>|}}<!--
{{(!}} class="mw-collapsible mw-collapsed"  
 
! style="text-align:left" {{!}} 5. {{{rule5}}}&nbsp;
 
{{!-}}
 
{{!}}{{{rule5d}}}
 
{{!)}}}}}<!--
 
  
-->{{{r6|
+
-->{{#if:{{{rule8|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">8. {{{rule8}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule8d}}}</div></div><div style="clear:both"></div>|}}<!--
{{(!}} class="mw-collapsible mw-collapsed"  
 
! style="text-align:left" {{!}} 6. {{{rule6}}}&nbsp;
 
{{!-}}
 
{{!}}{{{rule6d}}}
 
{{!)}}}}}<!--
 
  
-->{{{r7|
+
-->{{#if:{{{rule9|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">9. {{{rule9}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule9d}}}</div></div><div style="clear:both"></div>|}}<!--
{{(!}} class="mw-collapsible mw-collapsed"  
 
! style="text-align:left" {{!}} 7. {{{rule7}}}&nbsp;
 
{{!-}}
 
{{!}}{{{rule7d}}}
 
{{!)}}}}}<!--
 
  
-->{{{r8|
+
-->{{#if:{{{rule10|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">10. {{{rule10}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule10d}}}</div></div><div style="clear:both"></div>|}}<!--
{{(!}} class="mw-collapsible mw-collapsed"  
 
! style="text-align:left" {{!}} 8. {{{rule8}}}&nbsp;
 
{{!-}}
 
{{!}}{{{rule8d}}}
 
{{!)}}}}}<!--
 
  
-->{{{r9|
+
-->{{#if:{{{rule11|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">11. {{{rule11}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule11d}}}</div></div><div style="clear:both"></div>|}}<!--
{{(!}} class="mw-collapsible mw-collapsed"  
 
! style="text-align:left" {{!}} 9. {{{rule9}}}&nbsp;
 
{{!-}}
 
{{!}}{{{rule9d}}}
 
{{!)}}}}}<!--
 
  
-->{{{r10|
+
-->{{#if:{{{rule12|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">12. {{{rule12}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule12d}}}</div></div><div style="clear:both"></div>|}}<!--
{{(!}} class="mw-collapsible mw-collapsed"  
 
! style="text-align:left" {{!}} 10. {{{rule10}}}&nbsp;
 
{{!-}}
 
{{!}}{{{rule10d}}}
 
{{!)}}}}}<!--
 
  
-->{{{r11|
+
-->{{#if:{{{rule13|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">13. {{{rule13}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule13d}}}</div></div><div style="clear:both"></div>|}}<!--
{{(!}} class="mw-collapsible mw-collapsed"  
 
! style="text-align:left" {{!}} 11. {{{rule11}}}&nbsp;
 
{{!-}}
 
{{!}}{{{rule11d}}}
 
{{!)}}}}}<!--
 
  
-->{{{r12|
+
-->{{#if:{{{rule14|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">14. {{{rule14}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule14d}}}</div></div><div style="clear:both"></div>|}}<!--
{{(!}} class="mw-collapsible mw-collapsed"  
 
! style="text-align:left" {{!}} 12. {{{rule12}}}&nbsp;
 
{{!-}}
 
{{!}}{{{rule12d}}}
 
{{!)}}}}}<!--
 
  
-->{{{r13|
+
-->{{#if:{{{rule15|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">15. {{{rule15}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule15d}}}</div></div><div style="clear:both"></div>|}}<!--
{{(!}} class="mw-collapsible mw-collapsed"  
 
! style="text-align:left" {{!}} 13. {{{rule13}}}&nbsp;
 
{{!-}}
 
{{!}}{{{rule13d}}}
 
{{!)}}}}}<!--
 
  
-->{{{r14|
+
-->{{#if:{{{rule16|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">16. {{{rule16}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule16d}}}</div></div><div style="clear:both"></div>|}}<!--
{{(!}} class="mw-collapsible mw-collapsed"  
 
! style="text-align:left" {{!}} 14. {{{rule14}}}&nbsp;
 
{{!-}}
 
{{!}}{{{rule14d}}}
 
{{!)}}}}}<!--
 
  
-->{{{r15|
+
-->{{#if:{{{rule17|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">17. {{{rule17}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule17d}}}</div></div><div style="clear:both"></div>|}}<!--
{{(!}} class="mw-collapsible mw-collapsed"  
 
! style="text-align:left" {{!}} 15. {{{rule15}}}&nbsp;
 
{{!-}}
 
{{!}}{{{rule15d}}}
 
{{!)}}}}}<!--
 
  
-->{{{r16|
+
-->{{#if:{{{rule18|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">18. {{{rule18}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule18d}}}</div></div><div style="clear:both"></div>|}}<!--
{{(!}} class="mw-collapsible mw-collapsed"  
 
! style="text-align:left" {{!}} 16. {{{rule16}}}&nbsp;
 
{{!-}}
 
{{!}}{{{rule16d}}}
 
{{!)}}}}}<!--
 
  
-->{{{r17|
+
-->{{#if:{{{rule19|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">19. {{{rule19}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule19d}}}</div></div><div style="clear:both"></div>|}}<!--
{{(!}} class="mw-collapsible mw-collapsed"  
 
! style="text-align:left" {{!}} 17. {{{rule17}}}&nbsp;
 
{{!-}}
 
{{!}}{{{rule17d}}}
 
{{!)}}}}}<!--
 
  
-->{{{r18|
+
-->{{#if:{{{rule20|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">20. {{{rule20}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule20d}}}</div></div><div style="clear:both"></div>|}}<!--
{{(!}} class="mw-collapsible mw-collapsed"  
 
! style="text-align:left" {{!}} 18. {{{rule18}}}&nbsp;
 
{{!-}}
 
{{!}}{{{rule18d}}}
 
{{!)}}}}}<!--
 
  
-->{{{r19|
+
-->{{#if:{{{rule21|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">21. {{{rule21}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule21d}}}</div></div><div style="clear:both"></div>|}}<!--
{{(!}} class="mw-collapsible mw-collapsed"  
 
! style="text-align:left" {{!}} 19. {{{rule19}}}&nbsp;
 
{{!-}}
 
{{!}}{{{rule19d}}}
 
{{!)}}}}}<!--
 
  
-->{{{r20|
+
-->{{#if:{{{rule22|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">22. {{{rule22}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule22d}}}</div></div><div style="clear:both"></div>|}}<!--
{{(!}} class="mw-collapsible mw-collapsed"  
 
! style="text-align:left" {{!}} 20. {{{rule20}}}&nbsp;
 
{{!-}}
 
{{!}}{{{rule20d}}}
 
{{!)}}}}}<!--
 
  
-->{{{r21|
+
-->{{#if:{{{rule23|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">23. {{{rule23}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule23d}}}</div></div><div style="clear:both"></div>|}}<!--
{{(!}} class="mw-collapsible mw-collapsed"  
 
! style="text-align:left" {{!}} 21. {{{rule21}}}&nbsp;
 
{{!-}}
 
{{!}}{{{rule21d}}}
 
{{!)}}}}}<!--
 
  
-->{{{r22|
+
-->{{#if:{{{rule24|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">24. {{{rule24}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule24d}}}</div></div><div style="clear:both"></div>|}}<!--
{{(!}} class="mw-collapsible mw-collapsed"  
 
! style="text-align:left" {{!}} 22. {{{rule22}}}&nbsp;
 
{{!-}}
 
{{!}}{{{rule22d}}}
 
{{!)}}}}}<!--
 
  
-->{{{r23|
+
-->{{#if:{{{rule25|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">25. {{{rule25}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule25d}}}</div></div><div style="clear:both"></div>|}}<!--
{{(!}} class="mw-collapsible mw-collapsed"  
 
! style="text-align:left" {{!}} 23. {{{rule23}}}&nbsp;
 
{{!-}}
 
{{!}}{{{rule23d}}}
 
{{!)}}}}}<!--
 
  
-->{{{r24|
+
-->{{#if:{{{rule26|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">26. {{{rule26}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule26d}}}</div></div><div style="clear:both"></div>|}}<!--
{{(!}} class="mw-collapsible mw-collapsed"  
 
! style="text-align:left" {{!}} 24. {{{rule24}}}&nbsp;
 
{{!-}}
 
{{!}}{{{rule24d}}}
 
{{!)}}}}}<!--
 
  
-->{{{r25|
+
-->{{#if:{{{rule27|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">27. {{{rule27}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule27d}}}</div></div><div style="clear:both"></div>|}}<!--
{{(!}} class="mw-collapsible mw-collapsed"  
 
! style="text-align:left" {{!}} 25. {{{rule25}}}&nbsp;
 
{{!-}}
 
{{!}}{{{rule25d}}}
 
{{!)}}}}}<!--
 
  
-->{{{oldrulesdisable|
+
-->{{#if:{{{rule28|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">28. {{{rule28}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule28d}}}</div></div><div style="clear:both"></div>|}}<!--
{{!-}}
 
{{!}}style="padding-top: 0px"{{!}}
 
{{{rules}}}}}}
 
{{{staffdisable|{{!-}}
 
{{!}}style="padding-top: 25px"{{!}}'''STAFF INFORMATION:'''
 
{{{staff|}}}}}}
 
|-
 
|style="padding-top: 25px"|
 
{{{extra|}}}
 
|}
 
   
 
=Recommended xat Wiki Articles=
 
{{recommended articles}}
 
__NOTOC__
 
[[Category:Rules]]</includeonly><noinclude>
 
  
Attributes:
+
-->{{#if:{{{rule29|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">29. {{{rule29}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule29d}}}</div></div><div style="clear:both"></div>|}}<!--
* '''header''' - add important message at the very top of the rules
 
* '''header2''' - adds message right after with underline attribute (optional)
 
* '''rules''' - list of rules
 
* '''staff''' - notes to staff members
 
* '''extra''' - something extra that needs mentioning, see [[Trade Chat]] for example (optional)
 
* '''staffdisable''' - disable attribute '''staff''' and the english header that comes with it
 
Disabling attribute staff might be what you're after, if you have rules that are not in english. Information about staff can in that situation be included under attribute '''extra''' (see [[Rules:Fundos]] for an example).
 
----
 
'''Optional''': If you wish, you could have your rules expand to save space (see [[Rules:Help]] for an example)
 
  
Attributes:
+
-->{{#if:{{{rule30|}}}|<div style="font-weight: bold; float:left; margin-bottom: 5px" class="mw-collapsible mw-collapsed">30. {{{rule30}}} <div style="font-weight: normal; margin-bottom:10px" class="mw-collapsible-content">{{{rule30d}}}</div></div><div style="clear:both"></div>|}}<!--
*'''rule#''' - Short introduction of a rule
 
*'''rule#d''' - More detailed version of a rule
 
*'''oldrulesdisable''' - If you wish to disable rules attribute
 
Disabling rules attribute is not required if you wish to include additional information there (see [[Rules:Help]] for an example)
 
  
Example:
+
-->{{#if:{{{rules|}}}|<div style="padding-top: 0px">
*'''|rule1='''No profanity.
+
{{{rules}}}
*'''|rule1d='''Now here I explain in '''d'''etail what words and situations apply to this rule.
+
</div>}}<!--
  
At the bottom of your rules page you will find empty attributes from '''|r1= to |r25='''. These are there to disable spoilers that are not in use.
+
-->{{#if:{{{staff|}}}|<div style="padding-top: 25px">
 +
'''STAFF INFORMATION:'''
  
For example, if you have '''15 rules''' and you wish to include them in spoilers, then remove '''|r1= to |r15=''' from the bottom.
+
{{{staff}}}
 +
</div>}}<!--
  
If at any time you wish to add more rules or remove some, you need to adjust absent '''|r#=''' attributes to match the number of rules available.</noinclude>
+
-->{{#if:{{{extra|}}}|<div style="padding-top: 25px">
 +
{{{extra}}}
 +
</div>}}
 +
</div>
 +
   
 +
=Recommended xat Wiki Articles=
 +
{{recommended articles}}
 +
__NOTOC__
 +
[[Category:Rules]]</includeonly>

Revision as of 10:14, 22 August 2015

Attributes:

  • header - add important message at the very top of the rules
  • header2 - adds message right after with underline attribute (optional)
  • languages - value yes, if rules are translatable
  • rules - list of rules (optional, see below for rule spoilers)
  • staff - notes to staff members (optional)
  • extra - something extra that needs mentioning, see Trade Chat for example (optional)

Having the staff attribute not included might be what you're after, if you have rules that are not in english. Information about staff can in that situation be included under attribute extra (see Rules:Fundos for an example).


Optional: If you wish, you could have your rules expand to save space (see Rules:Help for an example)

Attributes:

  • rule# - Short introduction of a rule
  • rule#d - More detailed version of a rule

Example:

  • |rule=No profanity.
  • |ruled=Now here I explain in detail what words and situations apply to this rule.