Topic on Help talk:Extension:Kartographer

Jump to navigation Jump to search

Coordinates from Wikidata items (Property:P625)

Summary by Evad37

Not currently possible, see phab:T188291 for requested functionality.

Geraki (talkcontribs)

Can anyone understand why I do not get a map here?

<mapframe width=500 height=500 zoom=6 longitude=23.6 latitude=38>
  "type": "ExternalData",
  "service": "geoshape",
  "query": "
SELECT ?item ?coord ?Natura_2000_site_ID WHERE {
  ?item wdt:P3425 ?Natura_2000_site_ID.
  ?item wdt:P17 wd:Q41.
  ?item wdt:P625 ?coord.

In fact, not only the map fails, but also the interface! (no links to external maps etc.)

Geraki (talkcontribs)

I now understand this is a similar question to Help_talk:Extension:Kartographer/Archive_1#Wikidata_coordinates. Is there any way to include points where the coordinates are stored straight in Property:P625 in Wikidata? I find it strange that we can display maps with polygons called from OSM (through Wikidata), but not with points called straight from Wikidata items (at least there are no instructions on this).

Evad37 (talkcontribs)
Ayack (talkcontribs)
Evad37 (talkcontribs)
Ayack (talkcontribs)

@Evad37 Yes, please, I'm really interrested by an example !

Evad37 (talkcontribs)

Actually, reading over this discussion again, this may not be quite what you're looking for. In terms of queries, {{maplink}} can't do anything more than a plain <maplink> tag, other than make some of the syntax a bit easier to use, and allowing transclusion of JSON from another page. What the template can do is fetch the coordinates of items from Wikidata, if you know the Wikidata ids in advance -- as in {{maplink|type=point|id=Q...|type2=point|id2=Q...|...}} Anyway, I added some |raw= examples to the documentation for w:en:Template:Maplink; you could try experimenting further in your userspace or a sandbox on enwiki.

Ayack (talkcontribs)

Thanks, but unfortunately what @Geraki and I were trying to do was to display the results of a SPARQL query. Basically we want to display this map in Wikipedia.

I understand this is not possible which is a shame. Kartographer allows to do really complicated maps with lines or geoshapes for example but is not able to display some geopoints on a map without having to manually enter wikidata ids...

Reply to "Coordinates from Wikidata items (Property:P625)"