Can't use scrollwheel to zoom, nor can zoom out once zoomed in

This topic contains 18 replies, has 4 voices, and was last updated by  Alex Rollin 4 years, 2 months ago.

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

Open Support Ticket
  • Author
    Posts
  • #528575

    Romeo Crow
    Expired Member
    Post count: 54

    1. I found documentation about enabling mouse scrollwheel (https://wpgeodirectory.com/docs-v2/design/maps/) but I still don’t understand what to do; I want to enable it on my standard archive and details pages (the latter of which I’m using the archive page template for).

    2. On mobile, I can pinch to zoom, but if I tap on a bubble on the map, it enlarges the map area around that bubble, but I can’t then pinch to zoom OUT, only further in?!

    The site is https://WorldSchoolingHub.com

    #528583

    Kor
    Moderator
    Post count: 16516

    Hi Romeo Crow,

    THank for your post. Please allow me to answer your questions accordingly.

    1. You need to edit the map shortcode and insert the parameter below to enable scrollwheel.

    scrollwheel="1"

    2. Where can I see the map on your Website? It says I need to login. Does it work correctly on our demo? https://wpgeo.directory/supreme-directory/

    #528589

    Romeo Crow
    Expired Member
    Post count: 54
    This reply has been marked as private.
    #528612

    Alex Rollin
    Moderator
    Post count: 27815

    Where can I see the map on your Website?

    #528614

    Romeo Crow
    Expired Member
    Post count: 54
    #529351

    Alex Rollin
    Moderator
    Post count: 27815
    This reply has been marked as private.
    #529539

    Romeo Crow
    Expired Member
    Post count: 54

    Apologies for that, please try again using the log in details above.

    #529561

    Alex Rollin
    Moderator
    Post count: 27815
    This reply has been marked as private.
    #529665

    Romeo Crow
    Expired Member
    Post count: 54
    This reply has been marked as private.
    #529717

    Alex Rollin
    Moderator
    Post count: 27815

    Changing the Supreme Archive template map shortcode requires a customization of the template php file.

    The developers have been alerted and will let us know if there another workaround for that.

    #529925

    Naveen Giri
    Moderator
    Post count: 1559

    Hi Romeo ,

    You can use following code snippet to change the map shortcode.

    
    add_filter('sd_archive_gd_map_shortcode', 'sd_archive_gd_map_shortcode_custom_callback', 10, 1);
    function sd_archive_gd_map_shortcode_custom_callback( $shortcode ){
    	$shortcode = '[gd_map width="100%" height="425px" maptype="ROADMAP" zoom="0" map_type="directory" post_settings="1" post_type="gd_families" scrollwheel="1"]
    ';
    	return $shortcode;
    }
    

    Thanks

    #529961

    Romeo Crow
    Expired Member
    Post count: 54

    Thanks for the code. It worked – scrollwheel is enabled – but it also made the map smaller by half a screen.

    Here’s a quick video: https://drops.audience.ninja/Qwu7Wv8z

    Is there an additional/amended code that would sort that?

    Also, not the same point, but connected (happy to make another thread if you want); can you also provide a code/way to enable mouse scrolling on the maps on the Details page? (see above link/video to see what I mean)

    #529969

    Naveen Giri
    Moderator
    Post count: 1559

    Hi Romeo ,

    try it.

    
    
    add_filter('sd_archive_gd_map_shortcode', 'sd_archive_gd_map_shortcode_custom_callback', 10, 1);
    function sd_archive_gd_map_shortcode_custom_callback( $shortcode ){
    	$shortcode = '[gd_map width="100%" height="100vh" maptype="ROADMAP" zoom="0" map_type="auto" scrollwheel="1"]';
    	return $shortcode;
    }

    Thanks

    #529980

    Romeo Crow
    Expired Member
    Post count: 54

    That works like a charm, thanks!

    Should I open a separate ticket about getting the mouse scrollwheel to work on the Details page maps too, or can you supply the code here?

    #529984

    Naveen Giri
    Moderator
    Post count: 1559
    This reply has been marked as private.
Viewing 15 posts - 1 through 15 (of 19 total)

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

Open Support Ticket