Difference between revisions of "Template:Infobox"
From LFS Manual
Jump to navigationJump to searchm |
(width) |
||
| (10 intermediate revisions by the same user not shown) | |||
| Line 1: | Line 1: | ||
<includeonly><table style=" | <includeonly><table style=" | ||
| + | position: relative; | ||
| + | z-index: 1; | ||
border: 1px solid #a2a9b1; | border: 1px solid #a2a9b1; | ||
border-spacing: 3px; | border-spacing: 3px; | ||
| Line 10: | Line 12: | ||
font-size: 100%; | font-size: 100%; | ||
line-height: 1.5em; | line-height: 1.5em; | ||
| − | width: | + | width: {{{width|24em}}}; |
"> | "> | ||
{{#if:{{{title|}}} | {{#if:{{{title|}}} | ||
| Line 33: | Line 35: | ||
{{#if:{{{image|}}}| | {{#if:{{{image|}}}| | ||
<tr> | <tr> | ||
| − | <td colspan="2" style="text-align: center; {{{imagestyle|}}}">{{{image}}} | + | <td colspan="2" style="text-align: center; {{{imagestyle|}}}">{{{image}}}{{#if:{{{caption|}}}|<div style="text-align: center; {{{captionstyle|}}}">{{{caption}}}</div>}}</td> |
| − | |||
| − | |||
</tr>}} | </tr>}} | ||
{{#if:{{{image2|}}}| | {{#if:{{{image2|}}}| | ||
<tr> | <tr> | ||
| − | <td colspan="2" style="text-align: center; {{{image2style|}}}">{{{image2}}} | + | <td colspan="2" style="text-align: center; {{{image2style|}}}">{{{image2}}}{{#if:{{{caption2|}}}|<div style="text-align: center; {{{caption2style|}}}">{{{caption2}}}</div>}}</td> |
| − | |||
| − | |||
</tr>}} | </tr>}} | ||
{{#if:{{{image3|}}}| | {{#if:{{{image3|}}}| | ||
<tr> | <tr> | ||
| − | <td colspan="2" style="text-align: center; {{{image3style|}}}">{{{image3}}} | + | <td colspan="2" style="text-align: center; {{{image3style|}}}">{{{image3}}}{{#if:{{{caption3|}}}|<div style="text-align: center; {{{caption3style|}}}">{{{caption3}}}</div>}}</td> |
| − | |||
| − | |||
</tr>}} | </tr>}} | ||
| Line 1,838: | Line 1,834: | ||
{{{data100}}}</td> | {{{data100}}}</td> | ||
}} | }} | ||
| + | </tr> | ||
| + | }} | ||
| + | |||
| + | |||
| + | {{#if:{{{belowleft|}}}{{{belowright|}}}| | ||
| + | <tr> | ||
| + | <td style="text-align: center; vertical-align: top; width: 50%; {{{belowleftstyle|}}}">{{{belowleft}}}</td> | ||
| + | <td style="text-align: center; vertical-align: top; width: 50%; {{{belowrightstyle|}}}">{{{belowright}}}</td> | ||
</tr> | </tr> | ||
}} | }} | ||
Latest revision as of 16:18, 25 June 2025
Template documentation
Generic infobox template. Core infobox template for other, specialized templates, for example {{Infobox car}} and {{Infobox league}}.
Usage
Basic
| Markup | Renders as | ||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
{{Infobox
| above = Text above
| subheader = Subheader of the infobox
| header1 = Header 1 text
| label1 = Label 1
| data1 = Data 1
| header2 = Header 2 text
| label2 = Label 2
| data2 = Data 2
| header3 = Header 3 text
| data3 = Data 3
}}
|
| ||||||||||||||||
All parameters
Without any parameters
| Markup | Renders as |
|---|---|
{{Infobox}}
|
|
Custom styles
| Markup | Renders as | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
{{Infobox
| titlestyle = background: #ddd;
| abovestyle = background: #cfc;
| subheaderstyle = background: #ffc;
| title = Text in caption over infobox
| above = Text above
| subheader = Subheader of the infobox
| headerstyle = background: #ccf;
| labelstyle = background: #ddf;
| datastyle = background: #dedede;
| header1 = Header 1 text
| label1 = Label 1
| data1 = Data 1
| header2style = background: #cff;
| header2 = Header 2 text
| data2 = Data 2
}}
|
| ||||||||||||
Only data rows
| Markup | Renders as | ||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
{{Infobox
| above = Text above
| subheader = Subheader of the infobox
| label1 = Label 1
| data1 = Data 1
| label2 = Label 2
| data2 = Data 2
| label3 = Label 3
| data3 = Data 3
| data4 = Data 4
| data5 = Data 5
}}
|
| ||||||||||||||