Listing/Search page map mouse scroll function Supreme Directory

This topic contains 5 replies, has 3 voices, and was last updated by  Guust 6 years, 9 months ago.

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

Open Support Ticket
  • Author
    Posts
  • #389022

    Andrew T
    Expired Member
    Post count: 22

    Has the feature been added to allow mouse scroll on the map on the listing and search pages within the Supreme theme? I found the thread below where there is code mentioned to add but it also mentioned this being a coming update. Am I missing where to change this or should I attempt to add the code in this thread?

    https://wpgeodirectory.com/support/topic/search-and-listings-page-map-zoom/

    Thanks!
    Andrew

    #389026

    Guust
    Moderator
    Post count: 29970

    The change you are referring to, is the filter added to Supreme. That filter has been added so now you can use code to customize the Supreme maps.

    Add this filter code in functions.php or as a code snippet:

    
    
    add_filter('sd_map_shortcode_args', 'modify_sd_map_shortcode_args');
    function modify_sd_map_shortcode_args($args) {
          $args['scrollwheel'] = 'true';
          return $args;
    }

    For any other adjustments to the code, have a look at https://wpgeodirectory.com/docs/core-shortcodes/#listing

    Thanks

    #389027

    Andrew T
    Expired Member
    Post count: 22

    Thanks Guust, that did the trick! Much appreciated!

    #389030

    Guust
    Moderator
    Post count: 29970

    You’re welcome 🙂

    #391782

    memorex13
    Expired Member
    Post count: 540

    Hi,
    For me this code does not give me 500 server error, any other suggestions?
    Thank you

    add_filter(‘sd_map_shortcode_args’, ‘modify_sd_map_shortcode_args’);
    function modify_sd_map_shortcode_args($args) {
    $args[‘scrollwheel’] = ‘true’;
    return $args;
    }

    #391788

    Guust
    Moderator
    Post count: 29970

    @memorex13
    If that gives you errors, then I guess you added it to the wrong spot, or you have curly quotes instead of straight quotes.
    If we need to check it out, start your own topic please.

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

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

Open Support Ticket