Template:Infobox/doc

From EVE University Wiki
< Template:Infobox
Revision as of 12:15, 30 May 2022 by Evon R'al (talk | contribs) (Add dependency.)
Jump to: navigation, search
Description
This template is intended as a meta template: a template used for constructing other Infobox templates.
Dependencies
Uses
{{Infobox/row}}
Used by
{{CMBSiteInfo}}
{{Infobox agent}}
{{Infobox corporation}}
{{Infobox militia}}
Syntax
{{Infobox
| name           = {{subst:PAGENAME}}
| bodystyle      = 

| titlestyle     = 
| abovestyle     = 
| subheaderstyle = 
| title          = 
| above          = 
| subheader      = 

|   imagestyle   = 
| captionstyle   = 
|   image        = 
| caption        = 
|   image2       = 
| caption2       = 

| headerstyle    = 
|  labelstyle    = 
|   datastyle    = 

| header1  = 
|  label1  = 
|   data1  = 
| header2  = 
|  label2  = 
|   data2  = 
...
| header20 = 
|  label20 = 
|   data20 = 

| belowstyle     = 
| below          = 
}}
Parameters
name
If this parameter is present, "view/discuss/edit" links will be added to the bottom of the infobox, pointing to the named template.
above
Text to put within the uppermost cell of the table.
subheader, subheader2
additional title fields which fit below above.
image, image2
images to display at the top of the template. Use full image syntax, for example [[File:example.png|200px|alt=Example alt text]]. Image is centered by default.
caption, caption2
Text to put underneath the images.
Row parameters

A row with a label but no data is not displayed. This allows for the easy creation of optional infobox content rows. To make a row optional use a parameter that defaults to an empty string, like so:

label5 = Population
|data5  = {{{population|}}}
headern
Text to use as a header in row n.
labeln
Text to use as a label in row n.
datan
Text to display as data in row n.
Style parameters
bodystyle
Applies to the infobox table as a whole
abovestyle
Applies only to the above cell at the top.
imagestyle
Applies to the cell the image is in. This includes the text of the image caption, but you should set text properties with captionstyle instead of imagestyle in case the caption is moved out of this cell in the future.
captionstyle
Applies to the text of the image caption.
headerstyle
Applies to all header cells
labelstyle
Applies to all label cells
datastyle
Applies to all data cells
Sample output
{{Infobox |name = {{subst:PAGENAME}} |title = Test Infobox |above = Above text |subheader = Subheader above image |subheader2 = Second subheader |image = [[File:E-UNI White.png|200px|alt=Example alt text]] |caption = Caption displayed below Example-serious.jpg |header1 = Header defined alone |label1 = |data1 = |header2 = |label2 = Label defined alone does not display (needs data, or is suppressed) |data2 = |header3 = |label3 = |data3 = Data defined alone |header4 = All three defined (header, label, data, all with same number) |label4 = does not display (same number as a header) |data4 = does not display (same number as a header) |header5 = |label5 = Label and data defined (label) |data5 = Label and data defined (data) |below = Below text }}

gives...

Test Infobox
Above text
Subheader above image
Second subheader
Example alt text
Caption displayed below Example-serious.jpg
Header defined alone
Data defined alone
All three defined (header, label, data, all with same number)
Label and data defined (label) Label and data defined (data)
Below text
See also