links not working

New home Forums Basic Version Troubleshooting links not working

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #86302
    [email protected]
    Participant

    Hi, must be a simple one. Links were working from the pins on http://www.schoolofskate.com, now they’re not. Any help much appreciated.
    Thanks
    News

    #86307
    Matthew
    Moderator

    Hi there,

    Thank you for getting in touch with us, we do appreciate your time.

    I have taken a look at your site and it appears that you have some custom CSS code related to making your infowindow clickable so that it redirects to the marker’s link. I however cannot find any custom JS code related to this which may be the cause this.

    With that said, could you please save the below custom JS code into the “Custom JS” setting block (Maps -> Settings -> Custom JS):

    jQuery(function($){
        $(document).on('click', '.wpgmza-infowindow .wpgmza-infowindow-style-thin-column-right', function(event){
            let infowindow = $(event.currentTarget);
            let link = infowindow.find('a.wpgmza_infowindow_link');
            if(link.length > 0){
                window.location.href = link.attr('href');
            }
        })
    })

    Once done, please may you clear your browser cache and confirm if this helps?

    Kindest Regards,
    Matthew

    #86309
    [email protected]
    Participant

    This was a CSS only tweak, and didn’t require JS. It appears some change to mark up broke the code we wrote. I’ve updated the selector and it’s working now. Isn’t there a native way of doing this that doesn’t require custom code?

    #86316
    Matthew
    Moderator

    Hi there,

    Thank you for your response and time on this.

    Thank you for the confirmation regarding this and I am glad that its working now.

    Unfortunately we don’t have a native setting for this, however, I have added this as a item in our feature request list so that we can look into adding this in the future.

    I hope this helps?

    Kindest Regards,
    Matthew Lau

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.