Difference between revisions of "Template:PAGEHEADER"

From Vanguard Wiki
Jump to navigation Jump to search
m (fixed template example typo)
(quicklinks bar update)
Line 1: Line 1:
<noinclude>{{ PAGEHEADER | Image = Vanguard logo 041106.jpg | Size = 400 | URL = Main Page }}
+
<includeonly><div style="border:0; margin: 0.2em 0px 0px;">
[[Category:Template]][[Category:Header]]
+
<div style="background:#f9f9f9; padding:4px; border:1px solid #aaaaaa; margin-bottom:5px;">
 +
'''QUICKLINKS''' &#9724; [[Main_Page|VGOPlayers Wiki]] &#9724; [http://vgoplayers.com/community/ VGOPlayers Forum] &#9724; [http://vgoemulator.net VGOE Portal] &#9724; [https://www.vgoemulator.net/index.php?p=bugs VGOE Bugs] &#9724; [https://www.vgoemulator.net/index.php?p=projman VGOE Status] &#9724;
 +
</div>
 +
</div>
 +
{{#ifeq:{{lc:{{{Image}}}}}|none||[[File:{{#if:{{{Image|}}}|{{{Image}}}|{{PAGENAME}}.png}}|thumb|{{#if:{{{Size|}}}|{{{Size}}}px|250px}}|{{#if:{{{URL|}}}|link={{{URL}}}|link=https://www.vgoplayers.com/wiki/index.php/{{PAGENAME}}}}|frame|{{PAGENAME}}{{#if:{{{Caption|}}}|<br>{{{Caption}}}|}}]]}}<div style="float:right; clear:both; margin-left:0.5em;">__TOC__</div></includeonly><noinclude>
 +
{{PAGEHEADER |Image = Vanguard logo 041106.jpg |Size = 400 |URL = Main Page }}
 +
{{CATEGORY|Template|Header}}
 
==Template Description==
 
==Template Description==
* This template inserts a picture with the same name as the Page Title, and a TOC underneath that picture.  
+
* This template inserts a quicklinks bar, a picture with the name 'PAGENAME.png' and a TOC underneath that picture.  
 
==Template Usage==
 
==Template Usage==
 
* Can be used on any page by inserting the code block below at the top of the page.
 
* Can be used on any page by inserting the code block below at the top of the page.
 
{|
 
{|
|<pre>{{ PAGEHEADER | Image = myimagename.png | Caption = Caption Text | Size = 400 | URL = http://mypage.org/myitemlink }}</pre>
+
|<pre>{{PAGEHEADER |Image = Imagename.png |Caption = Caption Text |Size = 400 |URL = http://mypage.org/myitemlink }}</pre>
 
|-
 
|-
 
|text-align="center"|or
 
|text-align="center"|or
Line 29: Line 35:
 
==Wikicode==
 
==Wikicode==
 
<pre>
 
<pre>
<includeonly>{{#ifeq:{{lc:{{{Image}}}}}|none||[[File:{{#if:{{{Image|}}}|{{{Image}}}|{{PAGENAME}}.png}}|thumb|{{#if:{{{Size|}}}|{{{Size}}}px|250px}}|{{#if:{{{URL|}}}|link={{{URL}}}|link=https://www.vgoplayers.com/wiki/index.php/{{PAGENAME}}}}|frame|{{PAGENAME}}{{#if:{{{Caption|}}}|<br>{{{Caption}}}|}}]]}}<div style="float:right; clear:both; margin-left:0.5em;">__TOC__</div></includeonly>
+
<includeonly><div style="border:0; margin: 0.2em 0px 0px;">
</pre></noinclude><includeonly>{{#ifeq:{{lc:{{{Image}}}}}|none||[[File:{{#if:{{{Image|}}}|{{{Image}}}|{{PAGENAME}}.png}}|thumb|{{#if:{{{Size|}}}|{{{Size}}}px|250px}}|{{#if:{{{URL|}}}|link={{{URL}}}|link=https://www.vgoplayers.com/wiki/index.php/{{PAGENAME}}}}|frame|{{PAGENAME}}{{#if:{{{Caption|}}}|<br>{{{Caption}}}|}}]]}}<div style="float:right; clear:both; margin-left:0.5em;">__TOC__</div></includeonly>
+
<div style="background:#f9f9f9; padding:4px; border:1px solid #aaaaaa; margin-bottom:5px;">
 +
'''QUICKLINKS''' &#9724; [[Main_Page|VGOPlayers Wiki]] &#9724; [http://vgoplayers.com/community/ VGOPlayers Forum] &#9724; [http://vgoemulator.net VGOE Portal] &#9724; [https://www.vgoemulator.net/index.php?p=bugs VGOE Bugs] &#9724; [https://www.vgoemulator.net/index.php?p=projman VGOE Status] &#9724;  
 +
</div>
 +
</div>
 +
{{#ifeq:{{lc:{{{Image}}}}}|none||[[File:{{#if:{{{Image|}}}|{{{Image}}}|{{PAGENAME}}.png}}|thumb|{{#if:{{{Size|}}}|{{{Size}}}px|250px}}|{{#if:{{{URL|}}}|link={{{URL}}}|link=https://www.vgoplayers.com/wiki/index.php/{{PAGENAME}}}}|frame|{{PAGENAME}}{{#if:{{{Caption|}}}|<br>{{{Caption}}}|}}]]}}<div style="float:right; clear:both; margin-left:0.5em;">__TOC__</div></includeonly>
 +
</pre></noinclude>

Revision as of 12:45, 23 February 2020

PAGEHEADER

Template Description

  • This template inserts a quicklinks bar, a picture with the name 'PAGENAME.png' and a TOC underneath that picture.

Template Usage

  • Can be used on any page by inserting the code block below at the top of the page.
{{PAGEHEADER |Image = Imagename.png |Caption = Caption Text |Size = 400 |URL = http://mypage.org/myitemlink }}
or
{{PAGEHEADER
 | Image   = myimagename.png
 | Caption = Caption Text
 | Size    = 400
 | URL     = http://mypage.net/myitemlink
}}
or
{{PAGEHEADER}}
  • You can change the name of the image file if necessary, otherwise it will use 'pagename'+'.png' and try to display an image with that name.
  • If "URL" field is blank, the image will automatically link to https://www.vgoplayers.com/wiki/index.php/{{PAGENAME}}

Wikicode

<includeonly><div style="border:0; margin: 0.2em 0px 0px;">
<div style="background:#f9f9f9; padding:4px; border:1px solid #aaaaaa; margin-bottom:5px;">
'''QUICKLINKS''' ◼ [[Main_Page|VGOPlayers Wiki]] ◼ [http://vgoplayers.com/community/ VGOPlayers Forum] ◼ [http://vgoemulator.net VGOE Portal] ◼ [https://www.vgoemulator.net/index.php?p=bugs VGOE Bugs] ◼ [https://www.vgoemulator.net/index.php?p=projman VGOE Status] ◼ 
</div>
</div>
{{#ifeq:{{lc:{{{Image}}}}}|none||[[File:{{#if:{{{Image|}}}|{{{Image}}}|{{PAGENAME}}.png}}|thumb|{{#if:{{{Size|}}}|{{{Size}}}px|250px}}|{{#if:{{{URL|}}}|link={{{URL}}}|link=https://www.vgoplayers.com/wiki/index.php/{{PAGENAME}}}}|frame|{{PAGENAME}}{{#if:{{{Caption|}}}|<br>{{{Caption}}}|}}]]}}<div style="float:right; clear:both; margin-left:0.5em;">__TOC__</div></includeonly>