Jump to content

Module:Infobox dim/doc

From Wikipedia, the free encyclopedia
This is an old revision of this page, as edited by Hike395 (talk | contribs) at 12:11, 4 October 2024 (create doc). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.
(diff) ← Previous revision | Latest revision (diff) | Newer revision → (diff)


Code to convert information about physical size of objects into parameters for geohack or mapframes.

The following parameters describe the physical object size:

  • length_km
  • length_mi
  • width_km
  • width_mi
  • area_km2
  • area_mi2
  • area_ha
  • area_acre

In addition, the module can accept and convert between geohack parameters:

  • dim
  • scale
  • type (e.g., "mountain" or "city")
  • population (for type="city" only)

Usage

{{#invoke:Infobox dim|dim}}

Generates dim string (e.g, "24km") suitable for geohack link

{{#invoke:Infobox dim|scale}}

Generates scale (e.g, 100000) suitable for geohack link

{{#invoke:Infobox dim|zoom}}

Generates Open Street Map zoom level (e.g, 12) suitable for use in mapframes