Difference between revisions of "Template:Portal box"

From Wayne County, Ohio Online Resource Center
Jump to navigation Jump to search
 
(7 intermediate revisions by the same user not shown)
Line 1: Line 1:
<div style="float:{{{float}}}; width:50%; border:1px solid black; padding:0;">
+
<noinclude>
 +
==Usage==
 +
{| class="wikitable"
 +
|+ Parameters
 +
|-
 +
! Parameter
 +
! Required?
 +
! Note
 +
|-
 +
|| title
 +
|| yes
 +
|| Will be made bold and italic. Can be a link.
 +
|-
 +
| column
 +
|| yes
 +
|| Optional values:
 +
* left
 +
* right
 +
* both
 +
|-
 +
|| content
 +
|| yes
 +
|| Can take all wikitext. Might need to use HTML if you want to pass something complex.
 +
|-
 +
|| image
 +
|| no
 +
|| Provide as, e.g., <code>image=File:20000_squid_Nautilus_viewbay.jpg</code>. Will display a small thumbnail in upper left of content.
 +
|-
 +
|| imgsize
 +
|| no
 +
|| Width of image in pixels. Default is 100.
 +
|}
 +
 
 +
==Example source==
 +
<pre>{{Portal box
 +
| title=Captain Nemo
 +
| column=left
 +
| content=<p>'''Captain Nemo''' (in Latin '''Nobody''') — also known as '''Prince Dakkar''' — is a
 +
fictional character invented by the French science fiction author Jules Verne (1828–1905). Nemo
 +
appears in two of Verne's novels, ''Twenty Thousand Leagues Under the Sea'' (1870) and ''The
 +
Mysterious Island'' (1874), and makes a cameo appearance in Verne's play ''Journey Through the
 +
Impossible'' (1882).</p><p>Nemo, one of the most famous antiheroes in fiction, is a mysterious figure.
 +
The son of an Indian Raja, he is a scientific genius who roams the depths of the sea in his
 +
submarine, the ''Nautilus'', which was built on a deserted island. Nemo tries to project a stern,
 +
controlled confidence, but he is driven by a thirst for vengeance and a hatred of imperialism
 +
focused on the British Empire. He is also wracked by remorse over the deaths of his crew members
 +
and even by the deaths of enemy sailors.</p>
 +
| image=File:20000_squid_Nautilus_viewbay.jpg
 +
}}</pre>
 +
 
 +
==Example output==
 +
{{Portal box
 +
| title=Captain Nemo
 +
| column=left
 +
| content=<p>'''Captain Nemo''' (in Latin '''Nobody''') — also known as '''Prince Dakkar''' — is a fictional character invented by the French science fiction author Jules Verne (1828–1905). Nemo appears in two of Verne's novels, ''Twenty Thousand Leagues Under the Sea'' (1870) and ''The Mysterious Island'' (1874), and makes a cameo appearance in Verne's play ''Journey Through the Impossible'' (1882).</p><p>Nemo, one of the most famous antiheroes in fiction, is a mysterious figure. The son of an Indian Raja, he is a scientific genius who roams the depths of the sea in his submarine, the ''Nautilus'', which was built on a deserted island. Nemo tries to project a stern, controlled confidence, but he is driven by a thirst for vengeance and a hatred of imperialism focused on the British Empire. He is also wracked by remorse over the deaths of his crew members and even by the deaths of enemy sailors.</p>
 +
| image=File:20000_squid_Nautilus_viewbay.jpg
 +
}}
 +
</noinclude><includeonly><div style="{{#ifeq: {{{column}}} | left | float:left; width:49%; clear:left; | {{#ifeq: {{{column}}} | right | float:right; width:49%; clear:right; | {{#ifeq: {{{column}}} | both | clear:both; width:100%; |}}}}}} border:1px solid black; padding:0; margin-bottom:0.5em;">
 
<div style="border-bottom:1px solid black; background:lightsteelblue; font-weight:bold; font-style:italic; text-align:center;">{{{title}}}</div>
 
<div style="border-bottom:1px solid black; background:lightsteelblue; font-weight:bold; font-style:italic; text-align:center;">{{{title}}}</div>
<div style="padding:0.5em;">{{#if: {{{image|}}} | <div style="margin-right:0.5em;margin-bottom:0.5em; float:left;">[[{{{image}}}|100px|]]</div>|}}{{{content}}}</div>
+
<div style="padding:0.5em;">{{#if: {{{image|}}} | <div style="margin-right:0.5em;margin-bottom:0.5em; float:left;">[[{{{image}}}|{{{imgsize|100}}}px|]]</div>|}}{{{content}}}</div>
</div>
+
</div></includeonly>

Latest revision as of 16:19, 6 October 2014

Usage

Parameters
Parameter Required? Note
title yes Will be made bold and italic. Can be a link.
column yes Optional values:
  • left
  • right
  • both
content yes Can take all wikitext. Might need to use HTML if you want to pass something complex.
image no Provide as, e.g., image=File:20000_squid_Nautilus_viewbay.jpg. Will display a small thumbnail in upper left of content.
imgsize no Width of image in pixels. Default is 100.

Example source

{{Portal box
| title=Captain Nemo
| column=left
| content=<p>'''Captain Nemo''' (in Latin '''Nobody''') — also known as '''Prince Dakkar''' — is a 
fictional character invented by the French science fiction author Jules Verne (1828–1905). Nemo 
appears in two of Verne's novels, ''Twenty Thousand Leagues Under the Sea'' (1870) and ''The 
Mysterious Island'' (1874), and makes a cameo appearance in Verne's play ''Journey Through the 
Impossible'' (1882).</p><p>Nemo, one of the most famous antiheroes in fiction, is a mysterious figure.
 The son of an Indian Raja, he is a scientific genius who roams the depths of the sea in his 
submarine, the ''Nautilus'', which was built on a deserted island. Nemo tries to project a stern, 
controlled confidence, but he is driven by a thirst for vengeance and a hatred of imperialism 
focused on the British Empire. He is also wracked by remorse over the deaths of his crew members 
and even by the deaths of enemy sailors.</p>
| image=File:20000_squid_Nautilus_viewbay.jpg
}}

Example output

Captain Nemo
20000 squid Nautilus viewbay.jpg

Captain Nemo (in Latin Nobody) — also known as Prince Dakkar — is a fictional character invented by the French science fiction author Jules Verne (1828–1905). Nemo appears in two of Verne's novels, Twenty Thousand Leagues Under the Sea (1870) and The Mysterious Island (1874), and makes a cameo appearance in Verne's play Journey Through the Impossible (1882).

Nemo, one of the most famous antiheroes in fiction, is a mysterious figure. The son of an Indian Raja, he is a scientific genius who roams the depths of the sea in his submarine, the Nautilus, which was built on a deserted island. Nemo tries to project a stern, controlled confidence, but he is driven by a thirst for vengeance and a hatred of imperialism focused on the British Empire. He is also wracked by remorse over the deaths of his crew members and even by the deaths of enemy sailors.