Template:Infobox trail/doc

in articles about specific hiking trails or cycleways. The example on the right shows a good example of how a trail template is properly used.

Embed inside another infobox
The trail infobox can be embedded inside another infobox for seamless display of info. For example, a trail that is also a protected area, such as the Kal-Haven Trail. See the testcases for more examples.

Inserting the trail infobox inside the parent infobox
The trail infobox can only be inserted after certain field values of the parent template. Specifically, only after fields whose values are not passed to another template by the parent templates source code. In other words, the parent templates source code for the field has to output the fields' value without passing it to a template. This may require examining the parent templates source code. It is ok to insert after field values that contain internal  and external links.

Example: Note the &lt;div&gt; tag surrounding the governing_body wiki link. It is needed to reduce the vertical spacing between the governing_body field and the first hiking trail field, in this case, length.

Parent infobox encapsulation
The parent infobox needs to be encapsulated in a table as in the above example.

TemplateData
{	"params": { "name": { "label": "Name", "description": "Name of the trail; defaults to page name", "type": "string", "suggested": true },		"length_km": { "label": "Length in kilometers", "description": "Will convert to miles automatically", "type": "number" },		"length_mi": { "label": "Length in miles", "description": "Will convert to kilometers automatically", "type": "number" },		"length": { "label": "Length", "description": "No auto-conversion", "type": "string" },		"location": { "label": "Location", "description": "including park, state, county or region where appropriate and country", "suggested": true },		"trailheads": { "label": "Trailheads" },		"use": { "label": "Use", "example": "hiking, cycling", "type": "string", "suggested": true },		"photo": { "label": "Photo", "type": "wiki-file-name", "suggested": true },		"photo_size": { "label": "Photo size", "description": "Width of displayed photo, in pixels. Defaults to 250. ", "type": "number" },		"photo_alt": { "label": "Photo alternate text" },		"designation": { "label": "Designation", "example": "UK National Trail, US National Scenic Trail" },		"established": { "label": "Established", "suggested": true },		"elev_gain_and_loss": { "label": "Elevation gain/loss", "description": "Gain/loss with no units; use undefined undefined", "type": "string" },		"elev_change": { "label": "Elevation change", "description": "The sum of the altitude climbed or descended through the trail; use undefined undefined" },		"elev_change_ft": { "label": "Elevation change (ft)", "description": "The sum of the altitude climbed or descended through the trail; will be auto-converted", "type": "number" },		"elev_change_m": { "label": "Elevation change (m)", "description": "The sum of the altitude climbed or descended through the trail; will be auto-converted", "type": "number" },		"highest_m": { "label": "Highest point (m)", "description": "Highest point in meters; will be auto-converted", "type": "number" },		"highest_ft": { "label": "Highest point (ft)", "description": "Highest point in feet; will be auto-converted", "type": "number" },		"highest_name": { "label": "Highest point", "description": "Name of highest point in trail (for use with highest_ft or highest_m)", "type": "string" },		"lowest_m": { "label": "Lowest point (m)", "type": "number" },		"lowest_ft": { "label": "Lowest point (ft)", "type": "number" },		"lowest": { "label": "Lowest point" },		"lowest_name": { "label": "Name of lowest point", "description": "Name of lowest point in trail (for use with lowest_ft or lowest_m)", "type": "string" },		"grade": { "label": "Grade", "description": "Grade in percent" },		"difficulty": { "label": "Difficulty", "description": "The difficulty of the trail for a typical healthy person, based on a reliable source", "type": "string" },		"season": { "label": "Season", "description": "The season(s) that the trail may be hiked, or is easily accessible ", "type": "string" },		"months": { "label": "Months", "description": "The months that the trail may be hiked, or is easily accessible " },		"sights": { "label": "Sights" },		"hazards": { "label": "Hazards" },		"surface": { "label": "Surface", "description": "Material used as the surface of the trail", "example": "natural, gravel, ballast, asphalt", "type": "string" },		"ROW": { "label": "Right-of-way", "description": "The current or former Right of way, e.g. railroads or railways ", "type": "string" },		"maintainer": { "label": "Maintainer", "description": "Organization responsible for maintaining the route", "type": "string", "suggested": true },		"website": { "label": "Website", "description": "Use undefined or ", "suggested": true },		"waymark": { "label": "Waymark", "description": "Description of the waymark (sign or symbol) used to mark or signpost the route", "type": "string" },		"map": { "label": "Map image", "description": "Map of the trail, if an image ", "type": "wiki-file-name" },		"map_name": { "label": "Map image name", "description": "Map name. Default is \"Trail map\"", "default": "Trail map" },		"map_size": { "label": "Map image size", "description": "Size of map (either in px or %) " },		"map_alt": { "label": "Map image alt text", "type": "string" },		"map_caption": { "label": "Map image caption", "type": "string" },		"route": { "label": "Route diagram", "description": "Map of the trail, from a template in ", "type": "string", "example": "" },		"route_state": { "label": "Route diagram collapsed state", "description": "Collapsed state of route map ", "type": "string", "suggestedvalues": [ "collapsed", "uncollapsed" ],			"default": "uncollapsed" },		"embed": { "label": "Embed", "description": "Set to \"yes\" if this template is embedded inside another template", "type": "string", "suggestedvalues": [ "yes" ],			"default": "yes" },		"cellstyle": { "description": "Set to a class/style that matches the outer Infoboxes cell class/style so that the columns line up properly; see template documentation for more details", "type": "string" },		"title": { "description": "A first colored header before the main infobox, used when embedded, to show the trail name ", "type": "string" },		"caption": { "label": "Photo caption", "type": "string" }	},	"format": "block", "paramOrder": [ "name", "length_km", "length_mi", "length", "location", "trailheads", "use", "photo", "caption", "photo_alt", "photo_size", "designation", "established", "elev_gain_and_loss", "elev_change", "elev_change_ft", "elev_change_m", "highest_ft", "highest_m", "highest_name", "lowest_m", "lowest_ft", "lowest", "lowest_name", "grade", "difficulty", "season", "months", "sights", "hazards", "surface", "ROW", "maintainer", "website", "waymark", "map", "map_name", "map_size", "map_alt", "map_caption", "route", "route_state", "embed", "cellstyle", "title" ] }