• Hello

    I am setting up the WP-store locator on the following page, but google maps is not showing up:

    [ redundant link removed ]

    This is the code entered in the locations-2 page:

    [wpsl template=”below_map” map_type=”roadmap” auto_locate=”true” start_marker=”red” store_marker=”orange”]

    Thank you for your help

    • This topic was modified 6 years, 4 months ago by Jan Dembowski.

    The page I need help with: [log in to see the link]

Viewing 6 replies - 1 through 6 (of 6 total)
  • Plugin Author Tijmen Smit

    (@tijmensmit)

    Hi,

    If I view the source of your page, then it’s cut of ( ctrl + u ). The JavaScript file required to render the store locator isn’t being loaded, and that breaks it.

    If you for a second use a default WP theme, or disable all other plugins. Does it then work? I suspect it’s a problem with your theme.

    Are you comfortable with code? There’s one line in the code that you could try and change to fix this.

    Thread Starter nextGen

    (@kshkembi)

    Hi Tijmen

    Yes you are correct, I used a second default WP Theme and the map showed up correctly.

    I am not very comfortable with code but I might be able to insert the code.

    Can you please provide the code and what file do I need to update, what line on the file?

    thanks

    Plugin Author Tijmen Smit

    (@tijmensmit)

    Try to replace this line with the code below.

    wp_enqueue_script( 'wpsl-js', apply_filters( 'wpsl_gmap_js', WPSL_URL . 'js/wpsl-gmap'. $min .'.js' ), '', WPSL_VERSION_NUM, true );

    Let me know if that fixes it.

    Thread Starter nextGen

    (@kshkembi)

    Hi Tijmen

    I am still not sure what line number and what file to edit on the theme to enter the code above. I see page-about.php, index.php, header.php etc but i’m not sure which is the one i need to edit.

    Also I have another question on the following page: https://gondolierpizza.com/restaurants/locations/

    On the google map, it shows for development purposes only and I have to update the following code but i’m not sure what file to update, can you please help me with this too? This page is not a wp-store locator plugin, it came with the theme

    JS API Call:

    https://maps.googleapis.com/maps/api/js?key=AIzaSyCFkAf5zVBMhr4oiKpXkOtZNXvbTOWC7is v=3.exp&sensor=false&ver=1.0.0

    Plugin Author Tijmen Smit

    (@tijmensmit)

    Sorry for not explaining it better.

    If you go the /wp-content/plugins/wp-store-locator folder, then look for /frontend/class-frontend.php.

    Search for ‘wp_enqueue_script( ‘wpsl-js’, apply_filters( ‘wpsl_gmap_js”, and replace that whole line with this code.

    wp_enqueue_script( 'wpsl-js', apply_filters( 'wpsl_gmap_js', WPSL_URL . 'js/wpsl-gmap'. $min .'.js' ), '', WPSL_VERSION_NUM, true );

    The for development purposes only is because you either didn’t set up billing on the Google Cloud Platform, or there’s a problem with it. You can read more about that here.

    Thread Starter nextGen

    (@kshkembi)

    Hi Tijmen

    I tried to enter the above code on /wp-content/plugins/wp-store-locator folder /frontend/class-frontend.php but I wasn’t sure if that was the correct location and it didnt work.

    I really want to use the WP Store Locator plugin, is there a way we can schedule a TeamViewer meeting this week at your convenience and if you can please help me replace that code?

    Regards

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Google Map not showing up for the WP Store Locator’ is closed to new replies.