Hi there guys,
I took a tutorial on embedding Google maps into your web page and stripped it of all superfluous content to end up with a page containing just the elements of the map. You can find that here.
Then I tried to take those elements and place them in my webpage, which you can find here.
thanks for your time!
You’re calling jQuery before it is loaded, essentially:
This will result in:
ReferenceError: jQuery is not defined
Turning things around solves the problem:
Not sure if this is the exact cause of your error (I didn’t look), but it’s something you’ll need to sort out before proceeding.
Hi James and thanks very much for your help!
I tried moving jquery all the way up right below body start and it did get rid of the error but the map still continues to not show: https://scotchandiron.org/fivemin/1.html
I’m not seeing anything in console that would cause it to not work.
There are three errors there. Could they be causing JS to not run?
What happens to your minimal demo when you address the jQuery issue.
Went ahead and stripped the offending code out, removing all errors. Map still refuses to show, unfortunately: https://scotchandiron.org/fivemin/1.html
The thing is, there’s no issue on the minimal demo. The map shows and there are 0 errors. I only have an issue when moving the code to the page I’d like to embed the map on.
The problem is that you’re forgetting to give the map container any dimensions.
On the page that works you have:
Add that to the page you’re trying to make the map display on and all will be well
[EDIT] I am mistaken, sorry for the quick post…
I accidentally placed the style in a conditional PHP include that didn’t get triggered on that page. Once I fixed that mess up, it showed up just great. Thank you so much for all your help!
No worries. Glad you got it sorted.
This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.