FANDOM


m
m (Protected "Template:Object": Protecting all templates (move=sysop; edit=registered) - Frequent target of recent vandalism (‎[edit=autoconfirmed] (indefinite) ‎[move=sysop] (indefinite)))
 
(10 intermediate revisions by 9 users not shown)
Line 1: Line 1:
<includeonly>{| class="infobox" style="width: 225px; text-align: left; -moz-border-radius:10px; font-size: 85%" align="right" cellpadding="2"
+
<includeonly><infobox theme="object">
|-
+
<title><default>{{#if:{{{name|}}}|{{{name}}}{{#if:{{{featured|}}}|[[File:Featured.png|right|This article has been featured|link=Category:Featured]][[Category:Featured]]}}|{{#if:{{{Rname|}}}|{{{Rname}}}{{#if:{{{featured|}}}|[[File:Featured.png|right|This article has been featured|link=Category:Featured]][[Category:Featured]]}}|{{PAGENAME}}{{#if:{{{featured|}}}|[[File:Featured.png|right|This article has been featured|link=Category:Featured]][[Category:Featured]]}}}}}}</default></title>
! style="background: #166718; -moz-border-radius: 0.5em 0.5em 0 0; font-size: 100%;" align="center" colspan="2" |<font color="white">{{#if:{{{name|}}}|{{{name}}}|{{#if:{{{Rname|}}}|{{{Rname}}}|{{PAGENAME}}}}}}</font>
+
<image source="image">
{{!}}-
+
<caption source="caption"/>
{{#if: {{{image|}}} | {{!}} align=center colspan=2 style="padding: 1em 0; text-align: center;" {{!}} {{{image}}} }}
+
</image>
{{!}}- style="vertical-align: top;"
+
<group>
{{#if: {{{caption|}}} | {{!}} align=center colspan=2 {{!}} <small>{{{caption}}}</small> }}
+
<header></header>
{{!}}- style="vertical-align: top;"
+
<data source="name"><label>Name</label></data>
{{#if: {{{name|}}} | {{!}} '''Name''' {{!!}} {{{name}}} }}
+
<data source="origin"><label>Origin</label></data>
{{!}}- style="vertical-align: top;"
+
<data source="type"><label>Type</label></data>
{{#if: {{{origin|}}} | {{!}} '''Origin''' {{!!}} {{{origin}}} }}
+
<data source="owner"><label>Owner</label></data>
{{!}}- style="vertical-align: top;"
+
<data source="extrainfo1"><label>{{{extra1}}}</label></data>
{{#if: {{{type|}}} | {{!}} '''Type''' {{!!}} {{{type}}} }}
+
<data source="extrainfo2"><label>{{{extra2}}}</label></data>
{{!}}- style="vertical-align: top;"
+
<data source="extrainfo3"><label>{{{extra3}}}</label></data>
{{#if: {{{owner|}}} | {{!}} '''Owner''' {{!!}} {{{owner}}} }}
+
<data source="firstintroduced"><label>Introduced in</label></data>
{{!}}- style="vertical-align: top;"
+
<data source="lastseen"><label>Last appearance</label></data>
{{#if: {{{extrainfo1|<noinclude>-</noinclude>}}} |
+
</group>
! {{{extra1}}}
+
</infobox>
{{!}} {{{extrainfo1}}}
 
{{!}}-
 
}}
 
{{#if: {{{extrainfo2|<noinclude>-</noinclude>}}} |
 
! {{{extra2}}}
 
{{!}} {{{extrainfo2}}}
 
{{!}}-
 
}}
 
{{#if: {{{extrainfo3|<noinclude>-</noinclude>}}} |
 
! {{{extra3}}}
 
{{!}} {{{extrainfo3}}}
 
{{!}}-
 
}}
 
{{#if: {{{firstintroduced|}}} | {{!}} '''Introduced in''' {{!!}} {{{firstintroduced}}} }}
 
{{!}}- style="vertical-align: top;"
 
{{#if: {{{lastseen|}}} | {{!}} '''Last appearance''' {{!!}} {{{lastseen}}} }}
 
{{!}}- style="vertical-align: top;"
 
|}
 
 
[[Category:Objects]]
 
[[Category:Objects]]
 
</includeonly><noinclude>
 
</includeonly><noinclude>
Line 36: Line 36:
 
| lastseen =
 
| lastseen =
 
}}</pre>
 
}}</pre>
  +
'''Note:''' Add the parameter '''<code>featured = true</code>''' if the article has been ''[[:Category:Featured|featured]].''
  +
   
 
==Example==
 
==Example==
 
For example, adding the template with this information:
 
For example, adding the template with this information:
<pre><nowiki>{{</nowiki>Object
+
<pre>{{Object
 
| image = [[File:Imagination machine.jpg]]
 
| image = [[File:Imagination machine.jpg]]
 
| caption =
 
| caption =
Line 55: Line 57:
 
| lastseen =
 
| lastseen =
 
}}</pre><br clear="all">
 
}}</pre><br clear="all">
Results in this infobox:
+
{{Object
+
will result in this: {{Object
| image = [[File:Imagination machine.jpg]]
+
| image =
 
| caption =
 
| caption =
 
| name = Imagination Machine
 
| name = Imagination Machine
Line 72: Line 74:
 
| lastseen =
 
| lastseen =
 
}}
 
}}
 
 
[[Category:Infobox templates]] [[Category:Utility Templates]]
 
[[Category:Infobox templates]] [[Category:Utility Templates]]
 
</noinclude>
 
</noinclude>

Latest revision as of 15:23, March 2, 2019

Use the following code:

{{Object
| image           = 
| caption         = 
| name            = 
| origin          = 
| type            = 
| owner           = 
| extra1          =
| extrainfo1      = 
| extra2          = 
| extrainfo2      = 
| extra3          = 
| extrainfo3      =
| firstintroduced = 
| lastseen        = 
}}

Note: Add the parameter featured = true if the article has been featured.


ExampleEdit

For example, adding the template with this information:

{{Object
| image           = [[File:Imagination machine.jpg]]
| caption         = 
| name            = Imagination Machine
| origin          = Imaginary
| type            = Power control
| owner           = [[Jake]]
| extra1          = Likes to eat
| extrainfo1      = Oranges
| extra2          = On/off switch is
| extrainfo2      = Imaginary
| extra3          = Oranges are blue on
| extrainfo3      = Tuesdays
| firstintroduced = [[Rainy Day Daydream]]
| lastseen        = 
}}

will result in this:
Community content is available under CC-BY-SA unless otherwise noted.