Question

I have recently integrated WordPress into a clients website.

On the current contact page they have a Google Map with a marker. I have copied and pasted the code over to the new website and have created a new API key.

However on the new website, the map is a static map without markers.

The new website is: http://www.wrightandcobrighton.co.uk/contact

The old website with correct working map: http://www.wrightandcobrighton.co.uk/old/contact.html

What have I done wrong?

Was it helpful?

Solution 2

It turned out to be a jQuery conflict.

TypeError: $ is not a function $("#location").prepend('<div id="map"></div>');

jQuery(document).ready(function($) {
$("#location").prepend('<div id="map"></div>');
});

Worked.

I'll make sure I use pastebin in the future. Thanks for your time.

OTHER TIPS

There is a JavaScript error to do with Nivo Slider. Try commenting out or fixing your Nivo Slider JavaScript between lines 33 and 44. This error may be stopping the Google Maps code executing.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top