Cube Life: Island Survival Wiki
(Automated Import)
 
Line 1: Line 1:
 
{{doc/start}}
 
{{doc/start}}
 
This is just a generic infobox with a few sample fields
 
This is just a generic infobox with a few sample fields
  +
== Template structure ==
  +
<pre>
  +
{| class="infoboxtable" <!-- this class declaration tells the wiki this table is an infobox, and is based on css found in [[Mediawiki:Hydra.css]] -->
  +
|-
  +
! colspan="2" class="infoboxname" <!-- this class declaration tells the wiki this this row has special formatting --> | "{{{name}}}" <!-- this tells the wiki to insert the contents of a field called "name" here -->
  +
|-
  +
{{#if: {{{image|}}} | ! colspan="2" {{!}} [[File:{{{image}}}|250x250px]] | <includeonly>[[Category:Infoboxes lacking images]]</includeonly>}} <!-- this row specifies
  +
|-
  +
! colspan="2" class="infoboxdetails" <!-- this class declaration tells the wiki this this row has special formatting --> | Details
  +
|-
  +
{{#if: {{{race|}}} | {{!}} width=80 {{!}} <div>Race</div> {{!!}} {{{race}}} }} <!-- this row is one of the main data rows in the infobox -->
  +
|-
  +
{{#if: {{{location|}}} | {{!}} <div>Location(s)</div> {{!!}} {{{location}}} }}
  +
|-
  +
{{#if: {{{source|}}} | {{!}} <div>Source</div> {{!!}} {{{source}}} }}
  +
|-
  +
{{#if: {{{reward|}}} | {{!}} <div>Reward</div> {{!!}} {{{reward}}} }}
  +
|-
  +
{{#if: {{{related|}}} | {{!}} <div>Related</div> {{!!}} {{{related}}} }}
  +
|-
  +
{{#if: {{{ID|}}} | {{!}} <div>ID</div> {{!!}} {{{ID}}} }}
  +
|}
  +
</pre>
 
== Usage ==
 
== Usage ==
 
<pre>
 
<pre>

Revision as of 20:07, 24 July 2018

Template-info.png Documentation

This is just a generic infobox with a few sample fields

Template structure

{| class="infoboxtable" <!-- this class declaration tells the wiki this table is an infobox, and is based on css found in [[Mediawiki:Hydra.css]] -->
|-
! colspan="2" class="infoboxname" <!-- this class declaration tells the wiki this this row has special formatting --> |  "{{{name}}}" <!-- this tells the wiki to insert the contents of a field called "name" here -->
|-
{{#if: {{{image|}}} | ! colspan="2" {{!}} [[File:{{{image}}}|250x250px]] | <includeonly>[[Category:Infoboxes lacking images]]</includeonly>}} <!-- this row specifies 
|-
! colspan="2" class="infoboxdetails" <!-- this class declaration tells the wiki this this row has special formatting --> | Details 
|-
{{#if: {{{race|}}} | {{!}} width=80 {{!}} <div>Race</div> {{!!}} {{{race}}} }} <!-- this row is one of the main data rows in the infobox -->
|-
{{#if: {{{location|}}} | {{!}} <div>Location(s)</div> {{!!}} {{{location}}} }}
|-
{{#if: {{{source|}}} | {{!}} <div>Source</div> {{!!}} {{{source}}} }}
|-
{{#if: {{{reward|}}} | {{!}} <div>Reward</div> {{!!}} {{{reward}}} }}
|-
{{#if: {{{related|}}} | {{!}} <div>Related</div> {{!!}} {{{related}}} }}
|-
{{#if: {{{ID|}}} | {{!}} <div>ID</div> {{!!}} {{{ID}}} }}
|}

Usage

{{Infobox_example
| name     = 
| image    = 
| race     = 
| location = 
| source   = 
| reward   = 
| related  = 
| ID       =
}}

Example

Template:Infobox example

{{Infobox_example
| name     = Hydra guy
| image    = Curse hydra.png
| race     = Plushie
| location = Curse Headquarters
| source   = [[User:Encredechine{{!}}Encredechine]]
| reward   = 
| related  = Fun
| ID       =
}}

This is the documentation page, it should be transcluded into the main template page. See Template:Doc for more information.