Different map zoom levels

This topic contains 12 replies, has 3 voices, and was last updated by  Alex Rollin 5 years, 1 month ago.

We have moved to a support ticketing system and our forums are now closed.

Open Support Ticket
  • Author
    Posts
  • #475470

    Martin Steimann
    Lifetime Member
    Post count: 262

    Hello,

    I get different map zoom levels on a place details page and an event details place.

    On the place details page the map is zoomed out too far, and on events too close.

    I’ve examined the map tab item on the tab settings page, but there are no options for a zoom level.

    Regards,
    Martin

    #475477

    Kor
    Moderator
    Post count: 16516

    Hi Martin,

    Thanks for your post. Did you insert your GD map as a shortcode / widget? If you’re not sure, share your Website WP admin access here in private reply and I’ll check this out for you.

    Thanks!

    #475483

    Martin Steimann
    Lifetime Member
    Post count: 262
    This reply has been marked as private.
    #475486

    Kor
    Moderator
    Post count: 16516

    Hi Martin,

    Thanks for your reply. I get what you mean now. Unfortunately, there isn’t an option to adjust map zoom level in the “Tab”.

    You can only adjust the map zoom on widget maps.

    Thanks

    #475496

    Martin Steimann
    Lifetime Member
    Post count: 262

    Thanks Kor. But how comes that the zoom levels differ? And can you give me a hint how to hide the navigation overlay?

    #475520

    Kor
    Moderator
    Post count: 16516

    Hi Martin,

    Thanks for your reply. Which map are you comparing with? To remove the OSM overlay, you can apply the custom CSS code into the theme. Insert into Appearance > Customize > Additional CSS.

    .leaflet-routing-container {
        display:none!important;
    }
    #475525

    Martin Steimann
    Lifetime Member
    Post count: 262

    Thanks, the code works!

    I compare this map (event listing)
    https://edelmut.org/veranstaltungen/hoppetosse-in-wedel/#post_map

    to this map (place listing)
    https://edelmut.org/organisationen/haende-fuer-kinder-und-der-neue-kupferhof/#post_map

    Although there are place listings, which are zoomed in like the events example:
    https://edelmut.org/organisationen/berndtsteinkinder-stiftung/#post_map

    Others are way too much zoomed out:
    https://edelmut.org/organisationen/institut-fuer-konstruktive-konfliktaustragung-und-mediation-e-v/#post_map

    The zoom level seems kind of random to me.

    #475590

    Kor
    Moderator
    Post count: 16516
    This reply has been marked as private.
    #475618

    Alex Rollin
    Moderator
    Post count: 27815

    Hi!

    Be default the map shown on the detail page, the one that is in the tabs, that map uses the GD Map element with the option “Use post map zoom and type?” enabled. That means that whenever a user enters the add listing form and adjusts the map zoom, that zoom level is saved with the listing and used to determine the zoom of the map on the tab (or any other map shown on the page with the option enabled).

    So, want to change that?

    To override the default settings of shortcodes used in tabs you have to:

    Go to the tabs UI for the CPT
    Remove the tab
    Add a new tab (using the fieldgroup)
    Add a new shortcode field to that tab
    Include a GD Map shortcode that has the options you want (like turning off that option above)

    You might want to use a shortcode like this one:

    [gd_map width="100%" height="425px" maptype="ROADMAP" zoom="1" map_type="post"]

    What you don’t want is

    post_settings="1"

    because that will use the zoom settings of the user doing the input.

    Let us know how it goes

    #475858

    Martin Steimann
    Lifetime Member
    Post count: 262

    Thank you Alex. I followed your advice and added a new tab with your proposed shortcode, but the zoom level still gets overridden by the zoom level saved during a listing entry.

    So I deleted the tab and installed the GD Map widget instead, but no matter what zoom level I enter, the override still takes place.

    By the way: I have noticed a considerable slowdown of loading time of the tab selector on mobile devices. The page loads and content gets displayed, but the tab dropdown selector takes a few seconds to be filled with content.

    Therefore I am thinking of deleting the Map Tab completely and take the maps on sidebar route. But the issue of the „user preset zoom level during entry“ issue remains.

    Am I missing something? Can you please have a look by using the #475483 credentials?

    Regards,
    Martin

    #476010

    Alex Rollin
    Moderator
    Post count: 27815

    Try this one:

    
    [gd_map width="100%" height="425px" maptype="ROADMAP" zoom="14" map_type="post" post_settings="0"]
    #476070

    Martin Steimann
    Lifetime Member
    Post count: 262

    Brilliant – now it works and the desired zoom level gets properly displayed under the Map Tab!

    And regarding the Map Widget I have just found out that I have to set the Map Type to „Post Map“ in order to display the zoom level properly.

    It’s good to have both options working. Now I can decide whether to integrate and reveal the map under a tab or in the sidebar.

    Just in case someone else hast stumbled about this I have added a screenshot of my widget settings.

    Thanks again Alex!

    #476100

    Alex Rollin
    Moderator
    Post count: 27815

    Glad you got it working (and in more ways than one!).

    With V2 there are lots of ways to accomplish the end goal

Viewing 13 posts - 1 through 13 (of 13 total)

We have moved to a support ticketing system and our forums are now closed.

Open Support Ticket