Difference between revisions of "Template:Infobox"

Jump to navigation Jump to search
4,763 bytes added ,  02:11, 28 April 2018
no edit summary
(Created page with '<table class="wikitable {{{bodyclass|}}}" cellspacing="5" style="width: 23em; text-align: left; font-size: 88%; line-height: 1.5em; float: right; {{{bodystyle|}}}"><!-- Caption …')
 
 
(3 intermediate revisions by 2 users not shown)
Line 67: Line 67:
  Row 30
  Row 30
-->{{#if:{{{header30|}}}|<tr><th colspan="2" style="text-align: center; {{{headerstyle|}}}">{{{header30|}}}</th></tr>| {{#if:{{{label30|}}}|{{#if:{{{data30|}}}|<tr><td style="font-weight: bold; vertical-align: top; {{{labelstyle|}}}">{{{label30|}}}</td><td class="{{{class30|}}}" style="{{{datastyle|}}}">{{{data30|}}}</td></tr>}}|  {{#if:{{{data30|}}}|<tr><td colspan="2" class="{{{class30|}}}" style="text-align: center; {{{datastyle|}}}">{{{data30|}}}</td></tr>}} }} }}<!--
-->{{#if:{{{header30|}}}|<tr><th colspan="2" style="text-align: center; {{{headerstyle|}}}">{{{header30|}}}</th></tr>| {{#if:{{{label30|}}}|{{#if:{{{data30|}}}|<tr><td style="font-weight: bold; vertical-align: top; {{{labelstyle|}}}">{{{label30|}}}</td><td class="{{{class30|}}}" style="{{{datastyle|}}}">{{{data30|}}}</td></tr>}}|  {{#if:{{{data30|}}}|<tr><td colspan="2" class="{{{class30|}}}" style="text-align: center; {{{datastyle|}}}">{{{data30|}}}</td></tr>}} }} }}<!--
Row 31
-->{{#if:{{{header31|}}}|<tr><th colspan="2" style="text-align: center; {{{headerstyle|}}}">{{{header31|}}}</th></tr>| {{#if:{{{label31|}}}|{{#if:{{{data31|}}}|<tr><td style="font-weight: bold; vertical-align: top; {{{labelstyle|}}}">{{{label31|}}}</td><td class="{{{class31|}}}" style="{{{datastyle|}}}">{{{data31|}}}</td></tr>}}|  {{#if:{{{data31|}}}|<tr><td colspan="2" class="{{{class31|}}}" style="text-align: center; {{{datastyle|}}}">{{{data31|}}}</td></tr>}} }} }}<!--
Row 32
-->{{#if:{{{header32|}}}|<tr><th colspan="2" style="text-align: center; {{{headerstyle|}}}">{{{header32|}}}</th></tr>| {{#if:{{{label32|}}}|{{#if:{{{data32|}}}|<tr><td style="font-weight: bold; vertical-align: top; {{{labelstyle|}}}">{{{label32|}}}</td><td class="{{{class32|}}}" style="{{{datastyle|}}}">{{{data32|}}}</td></tr>}}|  {{#if:{{{data32|}}}|<tr><td colspan="2" class="{{{class32|}}}" style="text-align: center; {{{datastyle|}}}">{{{data32|}}}</td></tr>}} }} }}<!--
Row 33
-->{{#if:{{{header33|}}}|<tr><th colspan="2" style="text-align: center; {{{headerstyle|}}}">{{{header33|}}}</th></tr>| {{#if:{{{label33|}}}|{{#if:{{{data33|}}}|<tr><td style="font-weight: bold; vertical-align: top; {{{labelstyle|}}}">{{{label33|}}}</td><td class="{{{class33|}}}" style="{{{datastyle|}}}">{{{data33|}}}</td></tr>}}|  {{#if:{{{data33|}}}|<tr><td colspan="2" class="{{{class33|}}}" style="text-align: center; {{{datastyle|}}}">{{{data33|}}}</td></tr>}} }} }}<!--
Row 34
-->{{#if:{{{header34|}}}|<tr><th colspan="2" style="text-align: center; {{{headerstyle|}}}">{{{header34|}}}</th></tr>| {{#if:{{{label34|}}}|{{#if:{{{data34|}}}|<tr><td style="font-weight: bold; vertical-align: top; {{{labelstyle|}}}">{{{label34|}}}</td><td class="{{{class34|}}}" style="{{{datastyle|}}}">{{{data34|}}}</td></tr>}}|  {{#if:{{{data34|}}}|<tr><td colspan="2" class="{{{class34|}}}" style="text-align: center; {{{datastyle|}}}">{{{data34|}}}</td></tr>}} }} }}<!--
Row 35
-->{{#if:{{{header35|}}}|<tr><th colspan="2" style="text-align: center; {{{headerstyle|}}}">{{{header35|}}}</th></tr>| {{#if:{{{label35|}}}|{{#if:{{{data35|}}}|<tr><td style="font-weight: bold; vertical-align: top; {{{labelstyle|}}}">{{{label35|}}}</td><td class="{{{class35|}}}" style="{{{datastyle|}}}">{{{data35|}}}</td></tr>}}|  {{#if:{{{data35|}}}|<tr><td colspan="2" class="{{{class35|}}}" style="text-align: center; {{{datastyle|}}}">{{{data35|}}}</td></tr>}} }} }}<!--
Row 36
-->{{#if:{{{header36|}}}|<tr><th colspan="2" style="text-align: center; {{{headerstyle|}}}">{{{header36|}}}</th></tr>| {{#if:{{{label36|}}}|{{#if:{{{data36|}}}|<tr><td style="font-weight: bold; vertical-align: top; {{{labelstyle|}}}">{{{label36|}}}</td><td class="{{{class36|}}}" style="{{{datastyle|}}}">{{{data36|}}}</td></tr>}}|  {{#if:{{{data36|}}}|<tr><td colspan="2" class="{{{class36|}}}" style="text-align: center; {{{datastyle|}}}">{{{data36|}}}</td></tr>}} }} }}<!--
Row 37
-->{{#if:{{{header37|}}}|<tr><th colspan="2" style="text-align: center; {{{headerstyle|}}}">{{{header37|}}}</th></tr>| {{#if:{{{label37|}}}|{{#if:{{{data37|}}}|<tr><td style="font-weight: bold; vertical-align: top; {{{labelstyle|}}}">{{{label37|}}}</td><td class="{{{class37|}}}" style="{{{datastyle|}}}">{{{data37|}}}</td></tr>}}|  {{#if:{{{data37|}}}|<tr><td colspan="2" class="{{{class37|}}}" style="text-align: center; {{{datastyle|}}}">{{{data37|}}}</td></tr>}} }} }}<!--
Row 38
-->{{#if:{{{header38|}}}|<tr><th colspan="2" style="text-align: center; {{{headerstyle|}}}">{{{header38|}}}</th></tr>| {{#if:{{{label38|}}}|{{#if:{{{data38|}}}|<tr><td style="font-weight: bold; vertical-align: top; {{{labelstyle|}}}">{{{label38|}}}</td><td class="{{{class38|}}}" style="{{{datastyle|}}}">{{{data38|}}}</td></tr>}}|  {{#if:{{{data38|}}}|<tr><td colspan="2" class="{{{class38|}}}" style="text-align: center; {{{datastyle|}}}">{{{data38|}}}</td></tr>}} }} }}<!--
Row 39
-->{{#if:{{{header39|}}}|<tr><th colspan="2" style="text-align: center; {{{headerstyle|}}}">{{{header39|}}}</th></tr>| {{#if:{{{label39|}}}|{{#if:{{{data39|}}}|<tr><td style="font-weight: bold; vertical-align: top; {{{labelstyle|}}}">{{{label39|}}}</td><td class="{{{class39|}}}" style="{{{datastyle|}}}">{{{data39|}}}</td></tr>}}|  {{#if:{{{data39|}}}|<tr><td colspan="2" class="{{{class39|}}}" style="text-align: center; {{{datastyle|}}}">{{{data39|}}}</td></tr>}} }} }}<!--
Row 40
-->{{#if:{{{header40|}}}|<tr><th colspan="2" style="text-align: center; {{{headerstyle|}}}">{{{header40|}}}</th></tr>| {{#if:{{{label40|}}}|{{#if:{{{data40|}}}|<tr><td style="font-weight: bold; vertical-align: top; {{{labelstyle|}}}">{{{label40|}}}</td><td class="{{{class40|}}}" style="{{{datastyle|}}}">{{{data40|}}}</td></tr>}}|  {{#if:{{{data40|}}}|<tr><td colspan="2" class="{{{class40|}}}" style="text-align: center; {{{datastyle|}}}">{{{data40|}}}</td></tr>}} }} }}<!--


  Below
  Below
Line 78: Line 98:
=== Usage ===
=== Usage ===


Usage is similar to {{t|navbox}}, but with an additional distinction. Each row on the table can either be a "header", or it can have a label/data pair, or it can just be a data cell. These are mutually exclusive states so if you define a row to be both a header and a label/data pair, the label/data pair is overridden.
Each row on the table can either be a "header", or it can have a label/data pair, or it can just be a data cell. These are mutually exclusive states so if you define a row to be both a header and a label/data pair, the label/data pair is overridden.


Note that if you want to insert an image elsewhere other than the top of the infobox, or insert other "freeform" data, using a row with just a "data" field allows for that sort of thing.
Note that if you want to insert an image elsewhere other than the top of the infobox, or insert other "freeform" data, using a row with just a "data" field allows for that sort of thing.
Line 186: Line 206:
{{Infobox
{{Infobox
|name        = Infobox/doc
|name        = Infobox/doc
|bodystyle    =
|title        = Test Infobox
|title        = Test Infobox
|titlestyle  =  
|titlestyle  =  
34

edits

Navigation menu