This is a static archive of our old OpenStreetMap Help Site. Please post any new questions and answers at community.osm.org.

Show coordinates in uMap popup

0

I would like to create a uMap popup that also shows the coordinates of a marker. I tried to create a Popup content template in uMap with the placeholders {name}, {description}, {latitude} and {longitude}, but that does not work. Only the name and the description are shown. Am I using the wrong placeholders for the coordinates? Is there another way of showing the coordinates in the popup?

asked 18 Mar '23, 21:24

Palthe's gravatar image

Palthe
0224
accept rate: 0%

edited 27 Mar '23, 23:41


One Answer:

1

For the remote data in umap retrieved from overpass-turbo I use {lat} and {lon} for nodes:

properties of a node retrieved from overpass-turbo

answered 27 Jul '23, 08:55

iriman's gravatar image

iriman
29791318
accept rate: 33%

edited 27 Jul '23, 08:57

Dear Iriman,

Thanks for your answer. Using {lat} and {lon} works perfectly!
I did not thought about using the abbreviated versions of the names.
Do you know if there is some kind of list with all the placeholder-codes one can use?

Best regards,
Boudewijn.

(27 Jul '23, 22:04) Palthe

You're welcome. We can use any key name from key:value pairs in our data in the form {key} as placeholder. In the example data in picture above we can use {name}, {shop}, {lat}, {lon} and {id}. {id} will generate a mix of type and id values: {type}/{id}. I didn't find a list of placeholders. Happy that my suggestion also works for manual markers!

(29 Jul '23, 07:27) iriman

Source code available on GitHub .