Stop Google Maps Disappearing
August 19, 2009 ·
If you’ve got a website, chances are you have a Google map displaying somewhere on your site showing your location or the locations of the places you blog about. Static maps which don’t allow you to zoom in or move around, are a thing of the past. If your location is spectacular, why wouldn’t you want website visitors to be able to click on Satellite View and see the beach, sea and surf for real.
WordPress and Google Maps
When you copy the embed code for a Google map and paste into the html view of a WordPress post or page, it appears to work as it should until you try and edit the page. When you make changes to your page, the map disappears and you have to go back to Google, get the embed code and paste all over again. Very annoying and time-consuming.
The Plugin to Solve Your Problems
As you probably suspected and I have recently discovered, there is a plugin called XML Google Maps Plugin which solves this problem and it’s not complicated to use. (See screenshots below)
First you need a maps API key.
- Go to Google Maps API Sign up Page
- Sign in to your Google Account
- Enter the website address where the maps will be displaying (if your WordPress blog is in a separate folder,include this in the address, otherwise just type your website address)
- Tick that you have read terms and conditions
- Click on the Generate API Key button at the bottom
- Paste the key into a blank file on your computer and logout (you will need this key later)
Next you need the XML Maps Plugin on your website.
- Download the XML Google Maps plugin and upload to your plugins folder using ftp.
- OR if you are using one of the latest versions of WordPress, go to plugins on your admin bar, click Upload New, find the right plugin and upload it directly into your plugins folder.
- Activate the plugin in your plugins admin.
Adjust the Settings on the XML Google Maps admin page.
- Once you have activated the plugin, on your site, this will appear under Settings in your admin bar
- Paste your API Key into the box at the top
- Enter 0 in the caching box or leave as is
- Change the size the map will display at depending on the size of your pages (you can change this later)
- Choose whether you want map only or text with the map
- Choose whether you want the default view or satellite etc
- Save changes in any of the boxes on the right
How to Add a Map to Your Page/Post
- Go to Google maps
- Login to your Google account and create a map
- Once you are happy with the map, right click on the “View this map in Google Earth” link (top right) and select Copy Link Address.
- Login to your website and navigate to the page where you want the map to display.
- Enter text on your page where you want the map to appear. Eg. View map….
- Highlight the text and click on the Link/Anchor icon (same line as bold, italic etc)
- Paste your link address into the top box on the pop up window over the http
- Insert link and Publish or Save your page
Your Google map will magically appear on your website page. If you choose map only in your XML Google Map settings, the text will not be showing.
This plugin can do all sorts of amazing things which I haven’t covered in this article. Let me know in the comments section below if you’re using any of the other features what you think of them.
Other Articles You Might Enjoy
- Schedule Statistics Reports By Email - December 9th, 2009
- Google Translates Your Website - December 15th, 2008
- Register a Sitemap with Google - November 13th, 2008
- Google Analytics and Wordpress - October 17th, 2008
- Google Launches Intuitive Internet Browser - September 4th, 2008














Hi Jo,
Can this plugin also be used to represent a google map listing that is created in the Local Business Center rather than from Google Maps? If not – is there an alternative plugin that does it?
Yes. It works exactly the same but you need to go to the main google maps page – http://maps.google.co.nz/, sign in, then click on My Maps to find the ones you’ve created in the Local Business centre. Click on the one you want, then follow the rest of the instructions from step 3.
Jo,
Will the plugin mess with all the Google Maps I already have?
Also, can this only be used from within WordPress or can I continue to use Windows Live Writer to publish a draft with the Map?
Nice site. Thanks
Adding the plugin shouldn’t affect any Google maps you already have on your site. I’m not sure about Live Writer. Sorry.
hi jo, I have this issue of code disappearing or not displaying with other widgets – just been trying to get my new buybreambay twitter up on breambay.co.nz using a twitter based widget – script displays in html but not in visual or when loaded up.
any thoughts?
rosemary
Which twitter widget are you using?
Hi: I will be installing the XML Maps Plugin to keep my map from disappearing. Can I place a google map on a page and have text BESIDE it (not above or below)?
Thnaks, Kathy
Hi Kathy,
Yes. You can set the map alignment to left, right etc inside the Google Maps Settings page once activated.
I have a google map embeded on my homepage under “Trails”.
I have the problem of the disappearing map using html, and I have been trying to use this plugin for some time.
It just will not display the map. I have followed the instructions word for word.
Any ideas?
Hi James,
Have you added your google maps api key to the settings page?
I would try pasting the normal embed code into the spot on the homepage. As long as the plugin is setup this should still work.