Difference between revisions of "Template:Infobox MLB yearly/sandbox"

From blackwiki
Jump to navigation Jump to search
(commenting out documentation so it will not show in Category:Baseball infobox templates)
imported>WOSlinker
(sync)
Line 1: Line 1:
{| class="infobox vcard" style="font-size: 90%;"
+
{{ infobox
|-
+
| abovestyle  = background:lightyellow;
| style="margin-left: inherit; font-size: larger;" align="center" colspan="3" style="background:lightyellow;"| '''[[{{{season}}} Major League Baseball season|{{{season}}}]] <span class="fn org">{{{name}}}</span>''' <br> {{{misc}}}
+
| bodystyle  = width:280px
|-
+
| above      = [[{{{season}}} Major League Baseball season|{{{season}}}]] {{{name}}}'''
{{#if:{{{image<includeonly>|</includeonly>}}}|
+
| subheaderstyle = background:lightyellow;
<th colspan="3" style="text-align:center;">[[Image:{{{image}}}|{{{width|{{{imgwidth}}}}}}px|{{{alt|alt={{{alt}}}}}}]]<br>
+
| subheader = {{{misc|}}}
{{{caption<includeonly>|</includeonly>}}}</th>
+
| image      = {{#if:{{{image|}}}|[[File:{{{image}}}|250px]]}}
}}
+
| caption    = {{{caption|}}}
|-
+
| headerstyle = background:lightyellow;
| align="left" style="vertical-align: middle;" colspan="3" style="background:lightyellow;" | '''Major league affiliations'''
+
| datastyle = text-align:left
|-
+
| header1    = Major League affiliations
| align="left" colspan="3" |
+
| data2      = *'''[[{{{current league}}}]] (since [[{{{y1}}} Major League Baseball season|{{{y1}}}]])'''  
*'''[[{{{current league}}}]] (since [[{{{y1}}} Major League Baseball season|{{{y1}}}]])'''
+
| data3      = {{#if:{{{division|}}}|:*'''{{{division|}}} (since [[{{{y2}}} Major League Baseball season|{{{y2}}}]])'''}}
**'''{{{division}}} (since [[{{{y2}}} Major League Baseball season|{{{y2}}}]])'''
+
| header4    = Location
|-
+
| data5      = *'''{{{ballpark}}} (since [[{{{y4}}} Major League Baseball season|{{{y4}}}]])'''
| align="left" style="vertical-align: middle;" colspan="3" style="background:lightyellow;" | '''Location'''
+
| data6      = *'''{{{city}}} (since [[{{{y5}}} Major League Baseball season|{{{y5}}}]])'''
|-
+
| header7    = {{#if:{{{record|}}}{{{league place|}}}{{{divisional place|}}}|Results}}
| align="left" colspan="3" |
+
| label8      = Record
*'''{{{ballpark}}} (since [[{{{y4}}} Major League Baseball season|{{{y4}}}]])'''
+
| data8      = {{{record|}}}
*'''{{{city}}} (since [[{{{y5}}} Major League Baseball season|{{{y5}}}]])'''
+
| label9      = League place
|-
+
| data9      = {{{league place|}}}
| align="left" style="vertical-align: middle;" colspan="3" style="background:lightyellow;" | '''{{{season}}} information'''
+
| label10      = Divisional place
|- width="135px" align="left" style="vertical-align: top;"
+
| data10      = {{{divisional place|}}}
|| '''Owner(s)''' || width="135px" | {{{owners}}}
+
| header11    = {{#if:{{{owners|}}}{{{general managers|}}}{{{managers|}}}{{{television|}}}{{{radio|}}}{{{espntn|}}}|Other information}}
|-
+
| label12      = Owner(s)
{{#if:{{{general managers<includeonly>|</includeonly>}}} |
+
| data12      = {{{owners|}}}
{{!}} width="135px" align="left" style="vertical-align: top;" {{!}} '''General manager(s)'''
+
| label13      = General manager(s)
{{!}} width="135px" {{!}} {{{general managers}}}}}
+
| data13      = {{{general managers|}}}
|- width="135px" align="left" style="vertical-align: top;"
+
| label14    = Manager(s)
|| '''Manager(s)''' || width="135px" | {{{managers}}}
+
| data14      = {{{managers|}}}
|-
+
| label15    = Local television
{{#if:{{{television<includeonly>|</includeonly>}}} |
+
| data15      = {{{television|}}}
{{!}} width="135px" align="left" style="vertical-align: top;" {{!}} '''Local television'''
+
| label16    = Local radio
{{!}} width="135px" {{!}} {{{television}}}}}
+
| data16      = {{{radio|}}}
|-
+
| label17    = Stats
{{#if:{{{radio<includeonly>|</includeonly>}}} |
+
| data17      = {{#if:{{{espntn|}}}|[http://sports.espn.go.com/mlb/Statistics/Team/playerstats?team={{{espntn|}}}&seasonYear={{{season}}}&seasonType=2&pagetype=batting ESPN.com]<br />[http://www.baseball-reference.com/teams/{{{brtn|}}}/{{{season}}}.shtml BB-reference]}}
{{!}} width="135px" align="left" style="vertical-align: top;" {{!}} '''Local radio'''
+
| belowstyle = background:lightyellow;
{{!}} width="135px" {{!}} {{{radio}}}}}
+
| below      = '''{{#ifeq: {{{prev_season}}}|none||{{#if:{{{prev_season<includeonly>|</includeonly>}}}|[[{{{prev_season}}}{{!}}Previous season]]|[[{{#expr:{{{season}}}-1}} {{{name}}} season{{!}}&nbsp;&lt; Previous season]]}}}}&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{{#ifeq: {{{next_season}}}|none||{{#if:{{{next_season<includeonly>|</includeonly>}}}|[[{{{next_season}}}{{!}}Next season]]|[[{{#expr:{{{season}}}+1}} {{{name}}} season{{!}}Next season &nbsp;&gt;]]}}}}'''
|-
+
}}<noinclude>
{{#if:{{{espntn<includeonly>|</includeonly>}}} |
+
{{Documentation}}
{{!}} width="135px" align="left" style="vertical-align: top;" {{!}} '''Stats'''
+
<!-- Please add categories and interwiki links to /doc subpage, not here! -->
{{!}} width="135px" {{!}} [http://sports.espn.go.com/mlb/Statistics/Team/playerstats?team={{{espntn}}}&seasonYear={{{season}}}&seasonType=2&pagetype=batting ESPN.com]}}
+
</noinclude>
{{#if:{{{brtn<includeonly>|</includeonly>}}} | [http://www.baseball-reference.com/teams/{{{brtn}}}/{{{season}}}.shtml BB-reference]}}
 
|-
 
|{{#if:{{{last season<includeonly>|</includeonly>}}}{{{next season<includeonly>|</includeonly>}}} | <tr><th colspan="3" style="text-align:center; background:lightyellow;">'''{{{name}}} seasons'''}}</th></tr>
 
|-
 
{{!}} width="33%" style="text-align:center;" {{!}} '''Last season'''
 
{{!}} width="33%" style="text-align:center;" {{!}} '''This season'''
 
{{!}} width="33%" style="text-align:center;" {{!}} '''Next season'''
 
|-
 
{{!}} width="33%" style="text-align:center;" {{!}} {{{last season|}}}
 
{{!}} width="33%" style="text-align:center;" {{!}} '''{{{season|}}}'''
 
{{!}} width="33%" style="text-align:center;" {{!}} {{{next season|}}}
 
|}<!-- <noinclude>{{documentation}}</noinclude> -->
 

Revision as of 17:48, 26 June 2015

[[{{{season}}} Major League Baseball season|{{{season}}}]] {{{name}}}
Major League affiliations
  • [[{{{current league}}}]] (since [[{{{y1}}} Major League Baseball season|{{{y1}}}]])
Location
  • {{{ballpark}}} (since [[{{{y4}}} Major League Baseball season|{{{y4}}}]])
  • {{{city}}} (since [[{{{y5}}} Major League Baseball season|{{{y5}}}]])
[[{{{prev_season}}}|Previous season]]     [[{{{next_season}}}|Next season]]

Usage

{{Infobox MLB yearly
| name = Team Name 
| image = Relevant seasonal image
| image size = Size of the image, in pixels (default is 175px)
| caption = Caption for the image
| season = Season Year 
| misc = Mainly used for championships
| current league = [[name of league]] 
| y1 = Year team started playing in league 
| division = [[name of division]] 
| y2 = Year team started playing in division 
| ballpark = [[ballpark]] 
| y4 = Year team started playing in ballpark 
| city = [[city]] 
| y5 = Year team started playing in city 
| record = The overall record for the season with percentage
| divisional place = The place in which the team finished within its division
| league place = The place in which the team finished within its league (for pre-1969 season articles only)
| owners = [[Team owner(s)]]
| presbo = [[President of Baseball Operations]]
| general managers = [[General manager(s)]]
| managers = [[Team manager(s)]]
| television = [[local television network]]
| radio = [[local radio network]] 
| espntn = three character team abbreviation of team from espn
| brtn = three character team abbreviation from baseball-reference
}}

For the stats, enter the three character abbreviation from here. Milwaukee would be mil and Minnesota would be min. On the brtn, the name is just the espntn capitalized. You can find the 3 character name from here.

Optional parameters:

  • prev_season, next_season — The template automatically links to the franchise's previous and next seasons, using the team's name to form the name of the appropriate article. There are some cases, however, that have to be handled manually: