Difference between revisions of "Template:Infobox bus line/sandbox"

From blackwiki
Jump to navigation Jump to search
imported>Sameboat
imported>WOSlinker
(tidy style for better HTML5 compatibility)
 
(3 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{Infobox
+
{{infobox
  | bodystyle  = width: {{#if:{{{box_width|}}}|{{{box_width}}}|300px}}
+
| above      = {{br separated entries
  | headerstyle = background-color: #efefef
+
  |1 = {{#invoke:InfoboxImage|InfoboxImage|image={{{logo|}}}|size={{{logo_width|}}}|sizedefault=frameless|alt={{{logo_alt|}}}}}
  | above      = {{{name<includeonly>|{{PAGENAME}}</includeonly>}}}
+
|2 = <div style="{{#if:{{{logo|}}}|margin-top:.2em}}">{{{number|{{PAGENAME}}}}}</div>
| image      = {{#if:{{{image<includeonly>|</includeonly>}}}|[[File:{{{image}}}|<includeonly>{{px|</includeonly>{{{imagesize<includeonly>|</includeonly>}}}<includeonly>|200}}</includeonly>]]}} {{#if:{{{image2<includeonly>|</includeonly>}}}|<br />[[File:{{{image2}}}|<includeonly>{{px|</includeonly>{{{imagesize2<includeonly>|</includeonly>}}}<includeonly>|200}}</includeonly>]]}}
+
  }}
| caption    = {{{caption<includeonly>|</includeonly>}}}
+
| abovestyle  = background-color:{{{bgcolor|{{{box_color|#efefef}}}}}};color:{{{titlecolor|black}}};padding:5px;text-align:center;font-size:1.5em
| label2     = City
+
| bodystyle  = width:{{{box_width|25em}}}; font-size: 90%;
| data2     = {{{city<includeonly>|</includeonly>}}}
+
| subheader  = {{{subheader|}}}
| label3     = Operating agency
+
| subheader2 = {{#invoke:InfoboxImage|InfoboxImage|image={{{operatorlogo|}}}|size={{{oplogo_width|}}}|sizedefault=frameless}}
| data3     = {{{operating_agency<includeonly>|</includeonly>}}}
+
| image      = {{#invoke:InfoboxImage|InfoboxImage|image={{{image|}}}|size={{{image_width|}}}|sizedefault=frameless|alt={{{image_alt|}}}}}
| label4     = Route No.
+
| caption    = {{{caption|}}}
| data4     = {{{route#<includeonly>|</includeonly>}}}
+
| headerstyle = background-color: #efefef
| label5     = Region
+
 
| data5     = {{{region<includeonly>|</includeonly>}}}
+
| header1    = {{#if:{{{system|}}}{{{operator|}}}{{{garage|}}}{{{vehicle|}}}{{{livery|}}}{{{pvr|}}}{{{status|}}}{{{open|}}}{{{close|}}}{{{predecessors|}}}{{{night|}}}|Overview}}
| label6     = North end
+
 
| data6     = {{{north_end<includeonly>|</includeonly>}}}
+
| label2     = System
| label7     = South end
+
| data2       = {{{system|}}}
| data7     = {{{south_end<includeonly>|</includeonly>}}}
+
| label3     = Operator
| label8     = West end
+
| data3       = {{{operator|}}}
| data8     = {{{west_end<includeonly>|</includeonly>}}}
+
| label4     = {{#if:{{{depot|}}}|Depot|Garage}}
| label9   = East end
+
| data4       = {{#if:{{{depot|}}}|{{{depot|}}}|{{{garage|}}}}}
| data9     = {{{east_end<includeonly>|</includeonly>}}}
+
| label5     = Vehicle
| label10   = Major street
+
| data5       = {{{vehicle|}}}
| data10     = {{{major_streets<includeonly>|</includeonly>}}}
+
| label6     = Livery
| label11   = Length
+
| data6       = {{{livery|}}}
| data11     = {{{length<includeonly>|</includeonly>}}}
+
| label7     = Peak vehicle requirement
| label12   = Operating hour
+
| data7       = {{{pvr|}}}
| data12     = {{{hours<includeonly>|</includeonly>}}}
+
| label8     = Status
| label13   = Ended operation
+
| data8       = {{{status|}}}
| data13     = {{{ended_operation<includeonly>|</includeonly>}}}
+
| label9     = Began service
| label14    = Rush hour frequency
+
| data9       = {{{open|}}}
| data14     = {{{rush_hour_frequency<includeonly>|</includeonly>}}}
+
| label10     = Ended service
| label15    = Midday frequency
+
| data10     = {{{close|}}}
| data15     = {{{midday_frequency<includeonly>|</includeonly>}}}
+
| label11     = Predecessors
| label16    = Night frequency
+
| data11     = {{{predecessors|}}}
| data16     = {{{night_frequency<includeonly>|</includeonly>}}}
+
| label12     = Night-time
| label17    = Friday frequency
+
| data12     = {{{night|}}}
| data17     = {{{friday_frequency<includeonly>|</includeonly>}}}
+
 
| label18    = Saturday frequency
+
| header19   = {{#if:{{{locale|}}}{{{communities|}}}{{{landmarks|}}}{{{start|}}}{{{via|}}}{{{end|}}}{{{length|}}}{{{otherroutes|}}}{{{compete|}}}|Route}}
| data18     = {{{saturday_frequency<includeonly>|</includeonly>}}}
+
 
| label19    = Sunday frequency
+
| label20     = Route type
| data19     = {{{sunday_frequency<includeonly>|</includeonly>}}}
+
| data20      = {{{routetype|}}}
| label20    = Garage
+
| label21    = Locale
| data20     = {{{garage<includeonly>|</includeonly>}}}
+
| data21      = {{{locale|}}}
| label21    = First Operated
+
| label22     = Communities served
| data21     = {{{first_operated<includeonly>|</includeonly>}}}
+
| data22      = {{{communities|}}}
| label22    = Predecessor
+
| label23    = Landmarks served
| data22     = {{{predecessors<includeonly>|</includeonly>}}}
+
| data23      = {{{landmarks|}}}
| label23    = Connection
+
| label24     = {{#if:{{{termini|}}}|Termini|Start}}
| data23     = {{{connections<includeonly>|</includeonly>}}}
+
| data24      = {{#if:{{{termini|}}}|{{{termini}}}|{{{start|}}}}}
| label24    = Communitie served
+
| label25    = Via
| data24     = {{{communities_served<includeonly>|</includeonly>}}}
+
| data25      = {{{via|}}}
| label25    = Notable landmark served
+
| label26     = {{#if:{{{termini|}}}||End}}
| data25     = {{{landmark<includeonly>|</includeonly>}}}
+
| data26      = {{#if:{{{termini|}}}||{{{end|}}}}}
| belowstyle = vertical-align:middle;
+
| label27     = Length
| below      = {{#if:{{{map<includeonly>|</includeonly>}}}|
+
| data27      = {{{length|}}}
<table style="width:100%; margin:0; background-color:#F9F9F9" class="collapsible {{{map_state|}}}">
+
| label28    = Other routes
<tr><th style="background-color:#efefef; text-align: center;">{{{map_name|Map}}}</th></tr>
+
| data28      = {{{otherroutes|}}}
<tr><td align="center">
+
| label29     = Competition
{{#if:{{{map<includeonly>|</includeonly>}}}|[[File:{{{map}}}|<includeonly>{{px|</includeonly>{{{mapsize<includeonly>|</includeonly>}}}<includeonly>|280}}</includeonly>]]}}
+
| data29      = {{{compete|}}}
 +
 
 +
| header30    = {{#if:{{{level|}}}{{{level1|}}}{{{frequency|}}}{{{alt_frequency|}}}{{{time|}}}{{{day|}}}{{{ridership|}}}{{{fare|}}}{{{cash|}}}|{{#if:{{{ibus|}}}|<!--[[File:Ibus icon.PNG|25px|right|link=London iBus system]]-->}}Service}}
 +
 
 +
| label31    = Level
 +
| data31      = {{{level|}}}
 +
| label32     = Alt. level
 +
| data32      = {{{level1|}}}
 +
| label33    = Frequency
 +
| data33      = {{{frequency|}}}
 +
| label34     = Weekend frequency
 +
| data34      = {{{alt_frequency|}}}
 +
| label35    = Journey time
 +
| data35      = {{{time|}}}
 +
| label36     = Operates
 +
| data36      = {{{day|}}}
 +
| label37    = {{nowrap|Zone(s)}}
 +
| data37      = {{{zone|}}}
 +
| label38     = Daily ridership
 +
| data38      = {{{ridership|}}}
 +
| label39    = Annual patronage
 +
| data39      = {{{annualpatronage|}}}
 +
| label40     = Fare
 +
| data40      = {{{fare|}}}
 +
| label41    = Cash
 +
| data41      = {{{cash|}}}
 +
| label42     = Transfers
 +
| data42      = {{{transfers|}}}
 +
| label43    = Timetable
 +
| data43      = {{{timetable_link|}}}
 +
| label44     = Map
 +
| data44      = {{{map_link|}}}
 +
| belowstyle = vertical-align:middle;text-align:center;background-color:#efefef;font-size:.9em
 +
| below      = {{#if:{{{map|}}}{{{previous_line|}}}{{{next_line|}}}|
 +
<table style="width:100%; margin:0; background-color:#F9F9F9;{{#if:{{{map|}}}||display:none;}}" class="collapsible {{{map_state|collapsed}}}">
 +
<tr><th style="background-color:#efefef; text-align:center;">{{#if:{{{map_name|}}}|{{{map_name}}}|Route map}}</th></tr>
 +
<tr><td style="text-align:center;">
 +
{{{map}}}
 
</td></tr>
 
</td></tr>
 
</table>
 
</table>
}}<br>
+
<table style="width:100%;{{#if:{{{previous_line|}}}{{{next_line|}}}||display:none;}}">
{{#if:{{{rdt<includeonly>|</includeonly>}}}|
+
<td style="text-align:left;{{#if:{{{previous_line|}}}||display:none;}}">{{{previous_line}}} ←&nbsp;</td>
<table style="width:100%; margin:0; background-color:#F9F9F9;" class="collapsible {{{rdt_state|}}}">
+
<td style="text-align:right;{{#if:{{{next_line|}}}||display:none;}}">&nbsp;→ {{{next_line}}}</td>
<tr><th style="background-color:#efefef; text-align: center;">{{{rdt_name|Route diagram}}}</th></tr>
+
</table>}}{{{notes|}}}
<tr><td align="center">
+
}}<noinclude>{{documentation}}<!-- PLEASE ADD CATEGORIES TO THE /doc SUBPAGE, THANKS --></noinclude>
{{{rdt}}}
 
</td></tr>
 
</table>
 
}}
 
}}<noinclude>
 
 
 
==Usage==
 
<pre>
 
{{Infobox busline
 
|box_width          =
 
|name              =
 
|image              =
 
|imagesize          =
 
|image2            =
 
|imagesize2        =
 
|caption            =
 
|city              =
 
|operating_agency  =
 
|route#            =
 
|region            =
 
|north_end          =
 
|south_end          =
 
|west_end          =
 
|east_end          =
 
|major_streets      =
 
|length            =
 
|hours              =
 
|rush_hour_frequency=
 
|midday_frequency  =
 
|night_frequency    =
 
|friday_frequency  =
 
|saturday_frequency =
 
|sunday_frequency  =
 
|garage            =
 
|first_operated    =
 
|predecessors      =
 
|connections        =
 
|communities_served =
 
|landmark          =
 
|map                = image file name
 
|mapsize            =
 
|map_state          = show (default) or collapsed
 
|rdt                = {{map template name}}
 
|rdt_name          =
 
|rdt_state          = show (default) or collapsed
 
}}
 
</pre>
 
 
 
== Example ==
 
{{Infobox busline/sandbox
 
|box_width          = auto
 
|name              = Emerald Express (EmX)
 
|image              = placeholder.png
 
|imagesize          =200px
 
|caption            = Logo of Emerald Express
 
|city              = [[Eugene, Oregon|Eugene]]-[[Springfield, Oregon|Springfield]]
 
|operating_agency  = [[Lane Transit District]]
 
|route#            = Green Line
 
|region            =test
 
|north_end          =test
 
|south_end          =test
 
|west_end          = Eugene Station, downtown Eugene
 
|east_end          = Springfield Station, downtown Springfield
 
|major_streets      = West 11th Avenue, Franklin Boulevard
 
|length            =test
 
|hours              = 5:40am-10:45pm Weekdays,<br>7:10am-10:45pm Saturday,<br>8:10am-7:29pm Sunday
 
|rush_hour_frequency= :10
 
|midday_frequency  = :10
 
|night_frequency    = :20
 
|friday_frequency  =test
 
|saturday_frequency = :20
 
|sunday_frequency  = :20
 
|garage            =test
 
|first_operated    = 2007
 
|predecessors      = Route 11 Thurston
 
|connections        =test
 
|communities_served =test
 
|landmark          =test
 
|map                = placeholder.png
 
|mapsize            =
 
|map_state          = collapsed
 
|rdt                = {{infobox rdt|LTD EMX}}
 
|rdt_state          = show
 
}}
 

Latest revision as of 21:14, 29 June 2015

Infobox bus line/sandbox
Template documentation[view] [edit] [history] [purge]

All parameters

Template:Parameter names example

{{Infobox bus line
| logo            = <!-- bus logo (ex: Image_name.png) -->
| logo_width      = <!-- width of bus logo -->
| logo_alt        = <!-- logo image alternate text (only works if logo_width is supplied) -->
| number          = <!-- bus number or name of route (defaults to article name) -->
| bgcolor         = <!-- background color for infobox title (hex codes need a '#', i.e. #00ff33 not 00ff33) -->
| titlecolor      = <!-- color of the title text (hex codes need a '#') -->
| box_width       = <!-- width of the infobox itself -->
| subheader       = <!-- motto or alternate route title, etc. -->
| operatorlogo    = <!-- operator logo (ex: Image_name.png) -->
| oplogo_width    = <!-- width of the operator logo image -->
| image           = <!-- photo of the bus (ex: Image_name.png) -->
| image_width     = <!-- width of the main image -->
| image_alt       = <!-- alternate text for main image -->
| caption         = <!-- caption for the main image -->
| system          = 
| operator        = 
| garage          = 
| vehicle         = 
| livery          = 
| pvr             = 
| status          = 
| open            = <!-- {{Start date| YYYY| MM| DD| df=y}} -->
| close           = <!-- {{End date| YYYY| MM| DD| df=y}} -->
| predecessors    = 
| former_operator = 
| night           =
| routetype       = <!-- or |  routes = -->
| locale          = 
| communities     = 
| landmarks       = 
| termini         = <!-- used when route starts and stops at a single location, overrides the start and end parameters -->
| start           = 
| via             = 
| end             = 
| length          = 
| stations        = <!-- Overrides stops if used -->
| stops           = <!-- Overrides stations if used --->
| otherroutes     = 
| compete         = 
| level           = 
| level1          = 
| frequency       = 
| alt_frequency   = 
| time            = 
| day             = 
| zone            = 
| ridership       = 
| dailyridership  =
| annualpatronage = 
| transfers       = 
| timetable_link  = <!-- external link to an online timetable (ex: [http://www.example.com/timetable.html Line xx timetable]) --> 
| map_link        = <!-- external link to an online map (ex: [http://www.example.com/map.html Line xx map]) -->
| map             = <!-- map image (ex: [[File:Image_name.png| 200px]]) or  {{Infobox rdt}} -->
| map_state       = <!-- controls map starting visibility (use 'collapsed' to start hidden), defaults to hidden -->
| map_name        = <!-- name of the map (defaults to 'Route map') -->
| previous_line   = <!-- link to article of previous route if sequential -->
| system_nav      = <!-- link to article of system-->
| next_line       = <!-- link to article of next route if sequential -->
| notes           = <!-- anything special in small font, centered at the bottom of the infobox -->
}}

Example

787
Bad Title Example.png
Alternate text
Best damn bus in town!
Overview
SystemMBTA
OperatorJim
GarageBarton's
Vehicle898 Fewler
LiveryShield and Wheat
Peak vehicle requirement10
Statusdefunct
Began service1981
Ended service2010
PredecessorsTrolley #8
Night-time789 alt
Route
LocaleBoston
Communities servedBack Bay, South End
Landmarks servedMemorial Hospital
StartMaple St.
ViaCarnegie Rd.
EndElm St.
Length8 mi (13 km)
Other routes889, 908
Service
LevelDaily
FrequencyHourly
Weekend frequencyEvery two hours
Journey time45 minutes
Operates6:00 am – 8:00 pm
Ridership1,000
← 786  MBTA  788 →
{{Infobox bus line
| number        = 787
| logo          = Bad Title Example.png
| logo_width    = 100
| titlecolor    = white
| bgcolor       = #008000
| image         = Placeholder.png
| image_width   = 150
| image_alt     = Alternate text
| caption       = ''Best damn bus in town!''
| system        = MBTA
| operator      = Jim
| garage        = Barton's
| vehicle       = 898 Fewler
| livery        = Shield and Wheat
| pvr           = 10
| status        = defunct
| open          = 1981
| close         = 2010
| predecessors  = Trolley #8
| night         = 789 alt
| locale        = Boston
| communities   = Back Bay, South End
| landmarks     = Memorial Hospital
| start         = Maple St.
| via           = Carnegie Rd.
| end           = Elm St.
| length        = {{convert| 8| mi| km| abbr=on}}
| stops         = 43
| otherroutes   = 889, 908
| level         = Daily
| frequency     = Hourly
| alt_frequency = Every two hours
| time          = 45 minutes
| day           = 6:00 am – 8:00 pm
| ridership     = 1,000
| map           = [[File:Placeholder.png| 200px]]
| map_name      = 787 route
| previous_line = [[786]]
| system_nav    = MBTA
| next_line     = [[788]]
| notes         = {{portal-inline| Transportation| size=tiny}}
}}

Tracking category

Supporting template