Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

Setting the position on a map

  • jonsen
  • jonsen's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
6 years 10 months ago - 6 years 10 months ago #154717 by jonsen
Setting the position on a map was created by jonsen
Hey everyone!

I am trying to set the position on a map via Javascript/jQuery in LimeSurvey 2.65. I tried setting the transform attribute - but that only works in a controlled environment because it is based on pixels.

How can I change the coordinates directly? I also tried using a Leaflet command, but map.setView(new L.LatLng(40.737, 50.923), 3); doesn't work either - although it does on the Leaflet example page.

Can someone help me? (The default position is not enough because I want to animate different map positions.)

Best
Jones
Last edit: 6 years 10 months ago by jonsen.
The topic has been locked.
  • LouisGac
  • LouisGac's Avatar
  • Visitor
  • Visitor
6 years 10 months ago #154740 by LouisGac
Replied by LouisGac on topic Setting the position on a map
Hi, the map question is using google map or openLayers:
openlayers.org/

Btw, I agree we should provide a leaflet version....
The topic has been locked.
  • jonsen
  • jonsen's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
6 years 10 months ago #154884 by jonsen
Replied by jonsen on topic Setting the position on a map
Now I'm confused... It does say "Leaflet" at the bottom of the map?!

So what I'm trying to: Make it look like it's randomly jumping around the map until stopping at a "random" location (which in fact has been set by the default location setting beforehand).

Does anyone know how to do this?

Thanks!
The topic has been locked.

Lime-years ahead

Online-surveys for every purse and purpose