Template:Heading: Difference between revisions

From 118Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 1: Line 1:
<includeonly>{{br|{{{3|}}}}}<h2 style="border-bottom: none; font-size:large; font-weight:bold;">{{{1|}}}</h2><hr style="background:{{color|{{{2}}}}}; height:2px"></includeonly><noinclude>This template creates a heading style that uses a thin colored line specified by the user. It is an alternative to [[Template:Section]] and [[Template:Header]].
<includeonly>{{br|{{{3|}}}}}<h2 style="border-bottom: none; font-size:large; font-weight:bold;">{{{1|}}}</h2><hr style="background:{{color|{{{2}}}}}; height:2px"></includeonly><noinclude>This template creates a heading style that uses a thin colored line specified by the user. It is an alternative to [[Template:Section]] and [[Template:Header]].


<pre>{{Heading|Name of Heading|#6699cc}}</pre>
===Note about colors===
This template translates the standard color names for the divisions to the colors we use on the wiki: Thus '''<font color=maroon>Red</font>, <font color=darkgoldenrod>Gold</font>, <font color=steelblue>Blue</font>, <font color=teal>Teal</font>, <font color=purple>Violet</font>, <font color=black>Black</font>, <font color=dimgray>Silver</font>, and <font color=darkgreen>Green</font>''' are not necessarily the same as their true html color name. Any other html color name or HEX code will be shown as entered. To get around the preset color names above, use the raw HEX code (for instance, use #FF0000 to get <font color=#FF0000>this red</font> rather than using "Red" to get <font color=maroon>this red</font>. [http://www.w3schools.com/html/html_colornames.asp Consult this table for reference.]
 
===Example===
<pre>{{Heading|Name of Heading|Blue}}</pre>
 
{{Heading|Name of Heading|Blue}}
 
 


{{Heading|Name of Heading|#6699cc}}


===Clearing a Section===
===Clearing a Section===
Line 11: Line 18:


[[File:Trip.jpg|thumb|[[Template:Header|Hi, again!]]]]
[[File:Trip.jpg|thumb|[[Template:Header|Hi, again!]]]]
{{Heading|Before|maroon}}
{{Heading|Before|Red}}


[[File:Trip.jpg|thumb|[[Template:Header|Whoa!]]]]
[[File:Trip.jpg|thumb|[[Template:Header|Whoa!]]]]
{{Heading|After|green|clear}}
{{Heading|After|Gold|clear}}


[[Category:Templates]]
[[Category:Templates]]
__NOTOC__</noinclude>
__NOTOC__</noinclude>

Revision as of 19:33, 12 December 2014

This template creates a heading style that uses a thin colored line specified by the user. It is an alternative to Template:Section and Template:Header.

Note about colors

This template translates the standard color names for the divisions to the colors we use on the wiki: Thus Red, Gold, Blue, Teal, Violet, Black, Silver, and Green are not necessarily the same as their true html color name. Any other html color name or HEX code will be shown as entered. To get around the preset color names above, use the raw HEX code (for instance, use #FF0000 to get this red rather than using "Red" to get this red. Consult this table for reference.

Example

{{Heading|Name of Heading|Blue}}

Name of Heading




Clearing a Section

You can also add a
before the heading so that a thumbnail or sidebar will be displayed completely above it by adding "clear" to the end :

{{Heading|Name of Heading|Color|clear}}

Before



After