Template:Infobox: Difference between revisions

From Zelda Dungeon Wiki
Jump to navigation Jump to search
Want an adless experience? Log in or Create an account.
(add setbonus)
mNo edit summary
(37 intermediate revisions by 5 users not shown)
Line 2: Line 2:
| interview = {{Cat|Interviews|{{{2|{{PAGENAME}}}}}}}
| interview = {{Cat|Interviews|{{{2|{{PAGENAME}}}}}}}
| product | publication = {{Cat|Products|{{{2|{{PAGENAME}}}}}}}
| product | publication = {{Cat|Products|{{{2|{{PAGENAME}}}}}}}
}}</includeonly>{{Box|right|width=258px
}}</includeonly>{{Box|right|width=400px
| title = {{#if: {{{forumpage|}}}
| title = {{#if: {{{forumpage|}}}
   | <span class="plainlinks">[{{{forumpage}}} {{{name|{{PAGENAME}}}}}]</span>
   | <span class="plainlinks">[{{{forumpage}}} {{{name|{{PAGENAME}}}}}]</span>
Line 14: Line 14:
   | item | collectible | ring | weapon | object = infobox-item
   | item | collectible | ring | weapon | object = infobox-item
   | event | minigame | secret | skill | song | quest = infobox-knowledge
   | event | minigame | secret | skill | song | quest = infobox-knowledge
   | interview | member | person | product | publication | game | console | fan game = infobox-nondiegetic
   | interview | member | person | product | publication | game | console | fan game | track | company = infobox-nondiegetic
   }}
   }}
}}
}}
Line 35: Line 35:
}}{{#if: {{{gender|}}}
}}{{#if: {{{gender|}}}
| {{Infobox/Row|Gender|{{{gender}}}}}
| {{Infobox/Row|Gender|{{{gender}}}}}
}}{{#if: {{{trial|}}}
| {{Infobox/Row|Trial|{{{trial}}}}}
}}{{#if: {{{occupation|}}}
}}{{#if: {{{occupation|}}}
| {{Infobox/Row|Occupation|{{{occupation}}}}}
| {{Infobox/Row|Occupation|{{{occupation}}}}}
Line 54: Line 56:
}}{{#if: {{{weapon|}}}
}}{{#if: {{{weapon|}}}
| {{Infobox/Row|Effective<br/>Weapons|{{{weapon}}}}}
| {{Infobox/Row|Effective<br/>Weapons|{{{weapon}}}}}
}}{{#if: {{{weaponused|}}}
| {{Infobox/Row|Weapons Used|{{{weaponused}}}}}
}}{{#if: {{{element|}}}
}}{{#if: {{{element|}}}
| {{Infobox/Row|Element|{{{element}}}}}
| {{Infobox/Row|Element|{{{element}}}}}
Line 60: Line 64:
}}{{#if: {{{defense|}}}
}}{{#if: {{{defense|}}}
| {{Infobox/Row|Base Defense|{{{defense}}}}}
| {{Infobox/Row|Base Defense|{{{defense}}}}}
}}{{#if: {{{health|}}}
| {{Infobox/Row|Health|{{{health}}}}}
}}{{#if: {{{durability|}}}
}}{{#if: {{{durability|}}}
| {{Infobox/Row|Base Durability|{{{durability}}}}}
| {{Infobox/Row|Base Durability|{{{durability}}}}}
}}{{#if: {{{range|}}}
| {{Infobox/Row|Base Range|{{{range}}}}}
}}{{#if: {{{setbonus|}}}
}}{{#if: {{{setbonus|}}}
| {{Infobox/Row|Set Bonus|{{{setbonus}}}}}
| {{Infobox/Row|Set Bonus|{{{setbonus}}}}}
}}{{#if: {{{ingredients|}}}
| {{Infobox/Row|Ingredients|{{{ingredients}}}}}
}}<!--
}}<!--


Line 143: Line 153:
-->{{#if: {{{related|}}}
-->{{#if: {{{related|}}}
| {{Infobox/Row|Related|{{{related}}}}}
| {{Infobox/Row|Related|{{{related}}}}}
}}{{#if: {{{Leader|}}}
}}{{#if: {{{leader|}}}
| {{Infobox/Row|Leader|{{{leader}}}}}
| {{Infobox/Row|Leader|{{{leader}}}}}
}}{{#if: {{{ship|}}}
| {{Infobox/Row|Ship Set|{{{ship}}}}}
}}<!--
}}<!--


Line 162: Line 174:


CREDITS
CREDITS
-->{{#if: {{{developer|}}}{{{manufacturer|}}}{{{publisher|}}}{{{producer|}}}{{{director|}}}{{{author|}}}{{{editor|}}}{{{artist|}}}{{{designer|}}}{{{composer|}}}{{{arranged|}}}
-->{{#if: {{{developer|}}}{{{manufacturer|}}}{{{publisher|}}}{{{producer|}}}{{{director|}}}{{{author|}}}{{{editor|}}}{{{artist|}}}{{{designer|}}}{{{composer|}}}{{{arranged|}}}{{{host|}}}
| {{Infobox/Header|Credits}}
| {{Infobox/Header|Credits}}
   {{#if: {{{developer|}}}
   {{#if: {{{developer|}}}
Line 186: Line 198:
   }}{{#if: {{{arranged|}}}
   }}{{#if: {{{arranged|}}}
   | {{Infobox/Row|Arranged|{{{arranged}}}}}
   | {{Infobox/Row|Arranged|{{{arranged}}}}}
  }}{{#if: {{{host|}}}
  | {{Infobox/Row|Webhost|{{{host}}}}}
   }}
   }}
}}<!--
}}<!--


ATTRIBUTES
ATTRIBUTES
-->{{#if: {{{type|}}}{{{model|}}}{{{seasons|}}}{{{episodes|}}}{{{language|}}}{{{length|}}}{{{size|}}}{{{weight|}}}{{{color|}}}{{{quantity|}}}{{{ISBN|}}}{{{UPC|}}}
-->{{#if: {{{type|}}}{{{model|}}}{{{seasons|}}}{{{episodes|}}}{{{language|}}}{{{album|}}}{{{length|}}}{{{track|}}}{{{size|}}}{{{weight|}}}{{{color|}}}{{{quantity|}}}{{{ISBN|}}}{{{ASIN|}}}{{{catalog|}}}{{{wave|}}}{{{seriesnumber|}}}{{{UPC|}}}
| {{Infobox/Header|Attributes}}
| {{Infobox/Header|Attributes}}
   {{#if: {{{type|}}}
   {{#if: {{{type|}}}
   | {{Infobox/Row|Type|{{{type}}}}}
   | {{Infobox/Row|Type|{{{type}}}}}
  }}{{#if: {{{founded|}}}
  | {{Infobox/Row|Founded|{{{founded}}}}}
   }}{{#if: {{{model|}}}
   }}{{#if: {{{model|}}}
   | {{Infobox/Row|Model|{{{model}}}}}
   | {{Infobox/Row|Model|{{{model}}}}}
Line 202: Line 218:
   }}{{#if: {{{language|}}}
   }}{{#if: {{{language|}}}
   | {{Infobox/Row|Language|{{{language}}}}}
   | {{Infobox/Row|Language|{{{language}}}}}
  }}{{#if: {{{album|}}}
  | {{Infobox/Row|Album|{{{album}}}}}
   }}{{#if: {{{length|}}}
   }}{{#if: {{{length|}}}
   | {{Infobox/Row|Length|{{{length}}}}}
   | {{Infobox/Row|Length|{{{length}}}}}
  }}{{#if: {{{track|}}}
  | {{Infobox/Row|Track|{{{track}}}}}
   }}{{#if: {{{duration|}}}
   }}{{#if: {{{duration|}}}
   | {{Infobox/Row|Duration|{{{duration}}}}}
   | {{Infobox/Row|Duration|{{{duration}}}}}
Line 216: Line 236:
   }}{{#if: {{{ISBN|}}}
   }}{{#if: {{{ISBN|}}}
   | {{Infobox/Row|ISBN|{{{ISBN}}}}}
   | {{Infobox/Row|ISBN|{{{ISBN}}}}}
  }}{{#if: {{{ASIN|}}}
  | {{Infobox/Row|ASIN|{{{ASIN}}}}}
  }}{{#if: {{{catalog|}}}
  | {{Infobox/Row|Catalog Number|{{{catalog}}}}}
  }}{{#if: {{{wave|}}}
  | {{Infobox/Row|Wave|{{{wave}}}}}
  }}{{#if: {{{seriesnumber|}}}
  | {{Infobox/Row|Number|{{{seriesnumber}}}}}
   }}{{#if: {{{UPC|}}}
   }}{{#if: {{{UPC|}}}
   | {{Infobox/Row|UPC|{{{UPC}}}}}
   | {{Infobox/Row|UPC|{{{UPC}}}}}
Line 256: Line 284:
-->{{#if: {{{dept|}}}
-->{{#if: {{{dept|}}}
| {{Infobox/Row|Department|{{{dept}}}}}
| {{Infobox/Row|Department|{{{dept}}}}}
}}{{#if: {{{born|}}}
| {{Infobox/Row|Born|{{{born}}}}}
}}{{#if: {{{died|}}}
| {{Infobox/Row|Died|{{{died}}}}}
}}{{#if: {{{position|}}}
}}{{#if: {{{position|}}}
| {{Infobox/Row|Position|{{{position}}}}}
| {{Infobox/Row|Position|{{{position}}}}}
Line 291: Line 323:
| race =  
| race =  
| gender =  
| gender =  
| trial =
| occupation =  
| occupation =  
| member =  
| member =  
| leader        =  
| leader        =  
| ship          =
| purpose =  
| purpose =  
| special =  
| special =  
Line 300: Line 334:
| attack =  
| attack =  
| weapon =  
| weapon =  
| weaponused =
| element =  
| element =  
| power =  
| power =  
| defense =  
| defense =  
| health =
| durability =  
| durability =  
| range =
| setbonus =  
| setbonus =  
| ingredients =
| game =  
| game =  
| location =  
| location =  
Line 350: Line 388:
| composer =  
| composer =  
| arranged =  
| arranged =  
| album =
| track =
| host =
| type =  
| type =  
| model =  
| model =  
Line 362: Line 403:
| quantity =  
| quantity =  
| ISBN =  
| ISBN =  
| ASIN =
| catalog =
| wave =
| seriesnumber =
| UPC =  
| UPC =  
| walkthrough =  
| walkthrough =  
Line 375: Line 420:
| dept =  
| dept =  
| position =  
| position =  
| born =
| died =
| age =  
| age =  
| rank =  
| rank =  
Line 425: Line 472:
| game =  
| game =  
| location =  
| location =  
| trial =
| related =  
| related =  
}}
}}
Line 539: Line 587:
| location =  
| location =  
| cost =  
| cost =  
| ship              =
| use =  
| use =  
| dyeable =  
| dyeable =  
| enhanceable =  
| enhanceable =  
| setbonus =  
| setbonus =  
| ingredients =
| related =  
| related =  
}}
}}
Line 613: Line 663:
{{Infobox|person
{{Infobox|person
| image =  
| image =  
| born =
| died =
| game =  
| game =  
| dept =  
| dept =  
Line 737: Line 789:
| objective =  
| objective =  
| reward =  
| reward =  
}}
</pre>{{Float|end}}
{{Clear}}</div>
<div style="display: inline-block;">
===Track===
{{Float|left}}<pre>
{{Infobox|track
| image =
| game =
| album =
| track =
| duration =
| related =
}}
}}
</pre>{{Float|end}}
</pre>{{Float|end}}
Line 764: Line 830:
{{Usage/Example}}
{{Usage/Example}}
<pre>
<pre>
{{Box|width=258px|title=Demonstration|class=infobox}}
{{Box|width=320px|title=Demonstration|class=infobox}}
<table>
<table>
{{Infobox/Header|Header}}
{{Infobox/Header|Header}}
Line 781: Line 847:
</pre>
</pre>
{{Usage/Result|
{{Usage/Result|
{{Box|width=258px|title=Demonstration|class=infobox}}
{{Box|width=320px|title=Demonstration|class=infobox}}
<table>
<table>
{{Infobox/Header|Header}}
{{Infobox/Header|Header}}
Line 817: Line 883:
| event<br/>minigame<br/>secret<br/>skill<br/>song || {{Infobox|event|name=Knowledge|walkthrough=example}}
| event<br/>minigame<br/>secret<br/>skill<br/>song || {{Infobox|event|name=Knowledge|walkthrough=example}}
|-
|-
| interview<br/>member<br/>person<br/>product<br/>publication<br/>game<br/>console<br/>fan game || {{Infobox|interview|name=Nondiegetic|walkthrough=example}}
| interview<br/>member<br/>person<br/>product<br/>company<br/>publication<br/>game<br/>console<br/>fan game || {{Infobox|interview|name=Nondiegetic|walkthrough=example}}
|}
|}



Revision as of 01:09, June 29, 2020

size=40x40px This template is used on over 2500 pages. Take extra care when making changes, testing them in a sandbox first. If changes to this template require changes to pages that use it, you are responsible for making those changes.
Infobox

Purpose

This template is used on most pages to display quick high-level information on the subject.

Usage

Place this template at the top of the article, below any {{Hatnotes}} or {{Amboxes}}. Use whichever parameters are applicable; all are optional.

All available parameters:

{{Infobox|type
| name		= 
| logo		= 
| boxart	= 
| image		= 
| caption	= 
| title		= 
| race		= 
| gender	= 
| trial 	= 
| occupation	= 
| member	= 
| leader        = 
| ship          = 
| purpose	= 
| special	= 
| number	= 
| threat	= 
| attack	= 
| weapon	= 
| weaponused	= 
| element	= 
| power		= 
| defense	= 
| health	= 
| durability	= 
| range		= 
| setbonus	= 
| ingredients	=
| game		= 
| location	= 
| dungeon	= 
| when		= 
| natseason	= 
| boss		= 
| miniboss	= 
| enemies	= 
| inhab		= 
| characters	= 
| members	= 
| pointsint	= 
| item		= 
| prereq	= 
| shop		= 
| owner		= 
| cost		= 
| rarity	= 
| start		= 
| objective	= 
| learn		= 
| tell		= 
| reward	= 
| instrument	= 
| perform	= 
| use		= 
| effect	= 
| dyeable	= 
| enhanceable	= 
| related	= 
| release	= 
| release <platform1>	= <date1>
| release <platform2>	= <date2>
| ...
| developer	= 
| manufacturer	= 
| publisher	= 
| producer	= 
| director	= 
| author	= 
| editor	= 
| artist	= 
| designer	= 
| composer	= 
| arranged	= 
| album		= 
| track		= 
| host		= 
| type		= 
| model		= 
| seasons	= 
| episodes	= 
| language	= 
| length	= 
| duration	= 
| size		= 
| weight	= 
| color		= 
| quantity	= 
| ISBN		= 
| ASIN		= 
| catalog	= 
| wave		= 
| seriesnumber	= 
| UPC		= 
| walkthrough	= 
| guides	= 
| gallery	= 
| videos	= 
| music		= 
| date		= 
| interviewee	= 
| interviewer	= 
| description	= 
| source	= 
| dept		= 
| position	= 
| born		= 
| died		= 
| age		= 
| rank		= 
| joindate	= 
| website	= 
| posts		= 
| im		= 
}}
  • type — This defines the color of the title. See below for available types. (Optional.)
  • name — This is only necessary when the title of the Infobox should be different from the title of the article. Examples include shortening game titles to their subtitles and removing parenthetical specifications (e.g. Hyrule Castle (Twilight Princess)). (Optional. Default: article title)
  • boxart — Used only for games and consoles, this overrides the image parameter.
  • member — Any organization(s) of which the subject is a member.
  • related — Related subjects. For characters, specify the type of relation, e.g. "Talon (Father)" or "Talon (Boss)".
  • threat — A number 1-10.
  • attack — Attacks the enemy or boss may perform, including how much damage they do, using {{H}}.
  • weapon — Effective weapons.
  • release — Include as many release arguments as needed, in the form release <platform> = <date (using {{Region}})>. release by itself is for console release dates.

These defined types typically use the same parameters:

Boss

{{Infobox|boss
| image		= 
| caption	= 
| title		= 
| threat	= 
| attack	= 
| weapon	= 
| game		= 
| dungeon	= 
| reward	= 
}}

Character

{{Infobox|character
| image		= 
| title		= 
| race		= 
| gender	= 
| occupation	= 
| member	= 
| game		= 
| location	= 
| trial		= 
| related	= 
}}

Dungeon

{{Infobox|dungeon
| image		= 
| game		= 
| location	= 
| boss		= 
| miniboss	= 
| enemies	= 
| inhab		= 
| item		= 
| reward	= 
| walkthrough	= 
}}

Enemy

{{Infobox|enemy
| image		= 
| caption	= 
| threat	= 
| attack	=
| game		= 
| location	=
| weapon	=
| reward	= 
| related	= 
}}

Event

{{Infobox|event
| image		= 
| game		= 
| location	= 
| characters	= 
| when		= 
| related	= 
}}

Game

{{Infobox|game
| name		= 
| logo		= 
| boxart	= 
| caption	= 
| release <platform1>	= <date1>
| release <platform2>	= <date2>
| ...
| developer	= 
| publisher	= 
| producer	= 
| director	= 
| walkthrough	= 
| guides	= 
| gallery	= 
| videos	= 
| music		= 
}}

Group

{{Infobox|group
| image		= 
| game		= 
| location	= 
| leader        =
| purpose	= 
| members	= 
}}

Interview

{{Infobox|interview
| date		= 
| interviewee	= 
| interviewer	= 
| description	= 
| source	= 
}}

Item

{{Infobox|item
| image		= 
| game		= 
| location	= 
| cost		= 
| ship               =
| use		= 
| dyeable	= 
| enhanceable	= 
| setbonus	= 
| ingredients	=
| related	= 
}}

Weapon

{{Infobox|weapon
| image		= 
| game		= 
| element	= 
| power		= 
| durability	= 
| related	= 
}}

Location

{{Infobox|location
| image		= 
| game		= 
| inhab		= 
| pointsint	= 
| item		= 
| natseason	= 
| related	= 
}}

Member

{{Infobox|member
| forumpage	= 
| image		= 
| location	= 
| age		= 
| rank		= 
| joindate	= 
| posts		= 
| im		= 
}}

Minigame

{{Infobox|minigame
| image		= 
| game		= 
| location	= 
| owner		= 
| cost		= 
| objective	= 
| reward	= 
}}

Person

{{Infobox|person
| image		= 
| born		= 
| died		= 
| game		= 
| dept		= 
| position	= 
}}

Product

{{Infobox|product
| image		= 
| game		= 
| cost		= 
| rarity	= 
| release	= 
| developer	= 
| manufacturer	= 
| publisher	= 
| producer	= 
| director	= 
| author	= 
| editor	= 
| artist	= 
| designer	= 
| type		= 
| model		= 
| seasons	= 
| episodes	= 
| language	= 
| length	= 
| size		= 
| weight	= 
| quantity	= 
| color		= 
| ISBN		= 
| UPC		= 
| gallery	= 
}}

Race

{{Infobox|race
| image		= 
| special	= 
| game		= 
| location	= 
| characters	= 
}}

Ring

{{Infobox|ring
| image		= 
| number	= 
| game		= 
| location	= 
| prereq	= 
| effect	= 
}}

Secret

{{Infobox|secret
| prereq	= 
| learn		= 
| learn-img	= 
| tell		= 
| tell-img	= 
| reward	= 
| rew-img	= 
}}

Skill

{{Infobox|skill
| image		= 
| game		= 
| learn		= 
| perform	= 
| effect	= 
}}

Song

{{Infobox|song
| image		= 
| game		= 
| instrument	= 
| learn		= 
| perform	= 
| effect	= 
| related	= 
}}

Quest

{{Infobox|quest
| image		= 
| game		= 
| prereq	= 
| start		= 
| objective	= 
| reward	= 
}}

Track

{{Infobox|track
| image		= 
| game		= 
| album		= 
| track		= 
| duration	= 
| related	= 
}}

Adding Rows

If additional rows are needed, they can be added directly to this template. They generally take the form:

{{#if: {{{parameter|}}}
| {{Infobox/Row|Label|{{{parameter}}}}}
}}
  • parameter — The name of the parameter the row deals with. Be sure it hasn't already been used.
  • Label — The label that appears in the left column

Headers can also be added using {{Infobox/Header| text }}. They should be surrounded by an 'if' function that checks for any parameters in the section to which the header refers. Check the existing code for examples.

Each argument—up to three—passed to Infobox/Row represents one column. To adjust which cells are represented as labels, use the label parameter. label=0 makes the whole row data cells; label=1 is the default value; label=2 makes the first two cells labels; etc.

The widths of the columns can be defined using {{#vardefine:colNwidth|value}}, where value is the width (e.g. "50px") of the Nth column (i.e. define col3width for the third column). This can only be done once per column; once a cell has a defined width, further cells in the same column will share that width, even if the variable is reassigned.

Demo

The following code demonstrates different behaviors of Infobox/Row. In proper usage, each line should be surrounded by a #if function checking for parameters.

ExampleResult
{{Box|width=320px|title=Demonstration|class=infobox}}
<table>
{{Infobox/Header|Header}}
{{Infobox/Row|Colspan'd label}}
{{Infobox/Row|Label|Data}}
{{Infobox/Row|label=0|Colspan'd data}}
{{Infobox/Row|Default|Three column|Behavior}}
{{#vardefine:col3width|100px}}
{{Infobox/Row|label=0|Three|Data|Columns}}
{{Infobox/Row|label=2|Two|Labels|Data}}
{{Infobox/Row|label=3|Three|Label|Columns}}
{{#vardefine:col3width|75px}}
{{Infobox/Row|Different|Col|Width}}
</table>
{{Box/Bottom}}
Demonstration
Header

Colspan'd label

Label

Data

Colspan'd data

Default

Three column

Behavior

Three

Data

Columns

Two

Labels

Data

Three

Label

Columns

Different

Col

Width

Types and Colors

Common types of Infobox are associated with certain colors, as follows:

Types Color
[default]
Default
Guides

Walkthrough

example

boss
enemy
Hostile
Guides

Walkthrough

example

dungeon
Dungeon
Guides

Walkthrough

example

location
shop
Location
Guides

Walkthrough

example

character
group
race
shop owner
Character
Guides

Walkthrough

example

item
collectible
ring
weapon
object
Item
Guides

Walkthrough

example

event
minigame
secret
skill
song
Knowledge
Guides

Walkthrough

example

interview
member
person
product
company
publication
game
console
fan game
Nondiegetic
Guides

Walkthrough

example