• Resolved jeanpoldupont

    (@jeanpoldupont)


    Hello Camille, thank you for your plugin!

    How to do this: My markers should only be placed on a Belgian province.
    How do I make the marker placement map at the bottom of a post already zoomed in and centered on this Belgian province?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter jeanpoldupont

    (@jeanpoldupont)

      /**
         * Init leaflet
         */
        var cttm_map = L.map('travelersmap-container').setView(
          [45.280712, 5.89],
          3 //Zoom 3
        );

    I imagine that is what needs to be changed.
    Is it possible to do this without working in your code ?

    Plugin Author Camille V

    (@socrapop)

    Dear @jeanpoldupont,

    Yes indeed, you found the right line of code.

    Is it possible to do this without working in your code ?

    Well, unfortunately, I did that on the front-office part of the plugin, but I did not create a global map object in the back-office :/
    I will add it in the next update (v2), so you can add a function in your backoffice to change the view on init. I will let you know when it’s out ??

    In the meantime, you could change the code you found directly in the plugin code.
    Something like:

    var cttm_map = L.map('travelersmap-container').setView(
         [50.84, 4.6],
         7
    );

    Have a nice day,
    Camille

    Thread Starter jeanpoldupont

    (@jeanpoldupont)

    Thanks Camille !

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Placement map zoomed and centered’ is closed to new replies.