Difference between revisions of "Template:LegDist"

From BITPlan E-Bike Wiki
Jump to navigation Jump to search
Line 10: Line 10:
 
[[Category:Template]]
 
[[Category:Template]]
 
</noinclude><includeonly>{{#vardefine:from_latlon|{{#ask: [[Loc id::{{{from|}}}]] |?Loc latlon |format=plain |headers=hide }}}}
 
</noinclude><includeonly>{{#vardefine:from_latlon|{{#ask: [[Loc id::{{{from|}}}]] |?Loc latlon |format=plain |headers=hide }}}}
{{#vardefine:to_latlon|{{#ask: [[Loc id::{{{to|}}}]] |?Loc latlon |format=plain |headers=hide }}}}
 
{{#geodistance:{{#var:from_latlon}}|{{#var:to_latlon}}|unit=km}}
 
</includeonly><includeonly>{{#vardefine:from_latlon|{{#ask: [[Loc id::{{{from|}}}]] |?Loc latlon |format=plain |headers=hide }}}}
 
 
{{#vardefine:to_latlon|{{#ask: [[Loc id::{{{to|}}}]] |?Loc latlon |format=plain |headers=hide }}}}
 
{{#vardefine:to_latlon|{{#ask: [[Loc id::{{{to|}}}]] |?Loc latlon |format=plain |headers=hide }}}}
 
{{#geodistance:{{#var:from_latlon}}|{{#var:to_latlon}}|unit=km}}
 
{{#geodistance:{{#var:from_latlon}}|{{#var:to_latlon}}|unit=km}}
 
</includeonly>
 
</includeonly>

Revision as of 15:37, 27 November 2024

Template to calculate the distance between two Loc subobjects using their ids.

Usage

{{LegDist
|from=locationId1
|to=locationId2
}}


Fatal error: Required parameter 'location1' is missing