We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 5811
    • 1,717 Posts
    The zoom parameter is available only for the map without markers or with only one marker.

    As soon you have several markers, the zoom is deducted from the bounds of markers.
    Could you post your snippet call.
      • 18463
      • 121 Posts
      Martijn van Turnhout Reply #62, 15 years, 4 months ago
      Fair enough, good explanations. Besides my comments: gMaps is a great addition to the extras! My compliments on your work so far.

      Quote from: coroico at May 18, 2011, 08:17 AM

      @Martijn
      Agreed, that would be even more efficient.
      It will not be more efficient.
      1/ The geocoding process require to ask on fly to a google server the translation Address => lat,lng. So this consume performances. It could be acceptable for few markers not for lot of markers.
      2/ with an undetailed adress you can get several answers huh

      Instead of having 2 lat and long TV’s, you can have only 1 have "address" TV
      Gmaps use only one tv: LatLngTv. Not 2. And for the geocoding you usually need an address AND a latLng value. In this case the latLng is the point the closest of your address. See the geocoding api
        • 6537
        • 70 Posts
        Ok, thanks. Here is my snippet call:

        [!Gmaps?
          &mapWidth=`100%`
          &mapHeight=`320px`
          &zoom=`6`
          &mapLatLng=`0`
          &mkrLatLngTv=`mkrLatLng`
          &markers=`c51,c52,c53`
          &mkrClick=`info`
          &infoboxAjaxId=`67`
        !]


        Is it possible to tweak the zoom, or hardcode it for when the page first loads (or edit marker bounds)? All I’m really trying to achieve is for it to show 1 ’world’ on page load - as opposed to how it currently looks in the screenshot (max zoomed out). If I can get it to look like the screenshot attached (on first load) that would be great.

        Thanks again.
          • 5811
          • 1,717 Posts
          Could you try with:

          [!Gmaps?
            &mapWidth=`100%`
            &mapHeight=`320px`
            &mapLatLng=`0.,0.`  
            &mkrLatLngTv=`mkrLatLng` 
            &markers=`c51,c52,c53` 
            &mkrClick=`info` 
            &infoboxAjaxId=`67` 
          !]
            • 6537
            • 70 Posts
            Thanks Coroico, unfortunately it’s still not working though. I tried a test on a sandbox/test site and it behaved as expected (as in the 2nd screenshot), but I can’t seem to reproduce that on this site, even though I’ve copied everything the same.

            Any other ideas?!
              • 5811
              • 1,717 Posts
              is your site on line or does it run locally ? Could you send me an url by PM ?
                • 26422
                • 107 Posts
                I’ve tried to set this up using the cheat sheet but it seems very incomplete. Is there a step by step guide on how to get this going? The documentation leaves a lot of things out.

                Thanks.
                  Crawford Paul

                  Bridgecourt Web Design - Proudly using ModX CMS
                  Serving Welland, Niagara, Ontario, Canada and the world!
                  http://www.bridgecourt.com
                  • 5811
                  • 1,717 Posts
                  @dan_S8 : The trouble comes from the ratio between the size of the window(viewport) and the size of the markers bounds.

                  On this demo, I get also, the map twice If I set the mapHight to 320px and mapWidth=100%.
                  So I think the solution is somewhere between increasing the mapHight, decrease the mapWidth and/or have some shops in Antartica All the shops on the same latitude.
                    • 5811
                    • 1,717 Posts
                    @Bridgecourt,
                    I’ve tried to set this up using the cheat sheet but it seems very incomplete. Is there a step by step guide on how to get this going? The documentation leaves a lot of things out.
                    This is the only one document around Gmaps. So, I am interested to know where the documentation seems incomplete and what is missing. Let me know here or by PM what is unclear. And I will be happy to have your help to improve this document.
                      • 26422
                      • 107 Posts
                      With the help of Anselm (@anselmhannemann) I’m slowly getting my mind around your plugin. There are definitely big gaps in the cheat sheet. I will try and get some time together this week to put together a new tutorial on installing and using the snippet.
                        Crawford Paul

                        Bridgecourt Web Design - Proudly using ModX CMS
                        Serving Welland, Niagara, Ontario, Canada and the world!
                        http://www.bridgecourt.com