This is the template sandbox page for Template:ON former (diff). See also the companion subpage for test cases. |
Usage edit
This template uses Lua: |
This templates adds former Ontario highways to {{Infobox road}} using Parameter browse.
Code edit
{{Infobox road
....
|previous_type = ON
|previous_route = previous current
|next_type = ON
|next_route = next current
|browse = {{ON former|previous=previous former|next=next former}}
}}
Notes edit
- Only use
|previous=
when previous former > previous current - Only use
|next=
when next former < next current
Parameters edit
|previous=
The previous former route|next=
The next former route|width=
The width of the middle column (default :60px)
Example edit
Primary edit
Route information | |||||||
---|---|---|---|---|---|---|---|
Maintained by Ministry of Transportation of Ontario | |||||||
Location | |||||||
Country | Canada | ||||||
Province | Ontario | ||||||
Highway system | |||||||
| |||||||
|
{{Infobox road
|province = ON
|type = Hwy
|route = 60
|previous_type = ON
|previous_route = 58
|next_type = ON
|next_route = 61
|browse = {{ON former|previous=59}}
}}
Secondary edit
Route information | |||||||
---|---|---|---|---|---|---|---|
Maintained by Ministry of Transportation of Ontario | |||||||
Location | |||||||
Country | Canada | ||||||
Province | Ontario | ||||||
Highway system | |||||||
| |||||||
|
{{Infobox road
|province = ON
|type = Secondary
|route = 502
|previous_type = ON
|previous_route = QEW
|next_type = ON
|next_route = 510
|browse = {{ON former|previous=501|next=503}}
}}
Tertiary edit
Route information | |||||||
---|---|---|---|---|---|---|---|
Maintained by Ministry of Transportation of Ontario | |||||||
Location | |||||||
Country | Canada | ||||||
Province | Ontario | ||||||
Highway system | |||||||
| |||||||
|
{{Infobox road
|province = ON
|type = Secondary
|route = 804
|previous_type = ON
|previous_route = 802
|next_type = ON
|next_route = 805
|browse = {{ON former|previous=803}}
}}