Maps in Mediawiki: Difference between revisions
Appearance
Ttenbergen (talk | contribs) |
Ttenbergen (talk | contribs) mNo edit summary |
||
Line 1: | Line 1: | ||
[[Mediawiki]] can be used with the [[Mediawiki Extension Maps]] to display maps with markers based on coordinates. These coordinates can be provided explicitly or through data, such as through [[Mediawiki Extension Cargo]]. | |||
== Maps via Cargo Displayformat == | |||
Cargo can format its query results in some unexpected ways, and one of them is [https://www.mediawiki.org/wiki/Extension:Cargo/Display_formats#Maps as a map]. | |||
{{#cargo_query: table=Place | |||
|format = leaflet | |||
|fields = Name, Description, Coordinates | |||
|width = 400 | |||
|height = 300 | |||
}} | |||
== Maps extension == | == Maps extension == | ||
Line 16: | Line 26: | ||
|resizable=on | |resizable=on | ||
|layers=OpenStreetMap,Esri.WorldImagery | |layers=OpenStreetMap,Esri.WorldImagery | ||
|height=200 | |||
}} | }} | ||
== Encode locations in a cargo table to use them in queries== | == Encode locations in a cargo table to use them in queries== |
Revision as of 21:04, 2022 November 11
Mediawiki can be used with the Mediawiki Extension Maps to display maps with markers based on coordinates. These coordinates can be provided explicitly or through data, such as through Mediawiki Extension Cargo.
Maps via Cargo Displayformat
Cargo can format its query results in some unexpected ways, and one of them is as a map.
Maps extension
Maps extension with an inline Cargo query to set targets and a line
Encode locations in a cargo table to use them in queries
Template:Place defines Cargo Table Place.
Locations can be grabbed from Google Maps by right-clicking on an area and then clicking on the coordinates. They can be pasted into the Coordinates template paramater.
Here are the template calls (see edit view).