Marker at wrong position - Forum | JoomShaper
Awaiting an answer Extensions

Marker at wrong position

Asked by Dominik 1 year ago Last activity 1 year ago

Hello everyone
I have several positions on my Openstreetmap. When I use the default marker, everything is displayed correctly, no matter what zoom level I set. As soon as I use my own marker, the position is no longer correct. The further I zoom out, the more incorrect the position is.
In my screenshot, both markers have exactly the same latitude and longitude but are in completely different places on the map. How can I correct this?

https://prnt.sc/2PzjPVDigCQi

Thank you
Dominik

3 replies

Atick Eashrak Shuvo Staff

Apolozy for the inconvenience. I have checked your site, and the issue is caused by custom CSS added in Template Options -> Custom Code -> Custom CSS. The following CSS is affecting the marker positioning:

img.leaflet-marker-icon.leaflet-zoom-animated.leaflet-interactive{
  height:41px !important;
  width:25px !important;
}

Removing this CSS resolves the issue.

Dominik Asked this

Hi Atick

Thanks for the reply. If I remove this code it works but the marker is too big again (95x38px). I then uploaded a marker with the size 41x25px, but it is warped to the size of 95x38px. What else can I do so that the marker is displayed in the right place at the right size?

Domi

Atick Eashrak Shuvo Staff

Apologies for the inconvenience. There is an issue with the marker resizing when using a custom marker in OpenStreetMap. I have informed the developer about this, and it will be addressed in a future update. Thank you for your patience and understanding.

Dominik Asked this

This problem has apparently existed for years. What does future updates mean? But my customer needs it now...

Log in to reply.