Quick tricks with Google maps and iframes

Many of you will be familiar with the Google maps iframe insert that you can put into web pages and Facebook pages

Here are a couple of tricks to change the way it looks.

This  is what the iframe insert looks like

<iframe width=”300″ height=”300″ frameborder=”0″ scrolling=”no” marginheight=”0″
marginwidth=”0″
src=”http://maps.google.co.uk/maps?f=q&amp;source=s_q&amp;hl=en&amp;geocode=&amp;q=cb22+7np&amp;sll=52.127428,0.16816&amp;sspn=0.22552,0.676346&amp;ie=UTF8&amp;hq=&amp;hnear=Harston+CB22+7NP,+United+Kingdom&amp;t=k&amp;ll=52.138335,0.073814&amp;spn=0.015804,0.025749&amp;z=14&amp;output=embed”>
</iframe>

Remove the Google maps infobox

Add “&amp;iwloc=near”  to the end of the iframe src url

Get a satellite image of  Google maps iframe

change  ”&amp;t=m” to “&amp;t=k” and you will get the satellite image

Change it to “&amp;t=h” to get a hybrid map (map and satellite).

Change the zoom level of  Google maps iframe

The zoom level is controlled by the z parameter. The lower the number the more zoomed out you will be, so in this example I have changed it to “&amp;z=3″

The highest it will go is ”&amp;z=18″

There seems to be no way of changing the zoom control on the map which is a shame

About these ads
By Rupert Dick Posted in How To

10 comments on “Quick tricks with Google maps and iframes

  1. I’d echo that. The info box, satellite view and zoom level are nice tips. However I found this because, having located the iframe, either to the left or right of the column in my wordpress.com blog, I was hoping to put text alongside, as I might when I embed an image. Any suggestions?

  2. Duhhh…:-) Thanks very much. Works a treat. If I remember I’ll post the URI here so others can see it. once I’ve published the post. In your example above, I’m just seeing the URL for the map, and not the map itself. I just took a quick look at the source, and the map is looking for a box of 425px width, but your source only gives it 100px. I’m guessing you were in a hurry, so the solution is especially appreciated. Thanks again.
    D

  3. That’s really useful info, thanks. Since you’re an expert in this, I wonder if I could ask you a tech question about it? Someone asked me to fix their google maps popup. I have two jpg maps on a page. When you click on each one, you get an iframe google maps popup. They both look fine. The iframe says Image 1/2 at the bottom and has a next image button – which I suspect may be related to the problem. On the second image, when you click any nav button (zoom in/out) it zooms to the map on the first image. If I swap the order of the maps around – same thing happens – second image button zooms to map of the first. Any ideas what I can try? Unfortunately it’s not on the web yet so I can’t show you.

    • Hi Dave

      Not too sure I understand the problem but why have two map images you can have two iframes on the same page so why not go straight to the map.
      Difficult to see without the site in front of me

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s