A quick note added in February 2011. Google has now removed the iwloc part of the url in most cases. To remove the pin, you can now add &iwloc=near to the end of the iframe src attribute. So….
<iframe width=”300″ height=”300″ frameborder=”0″ scrolling=”no” marginheight=”0″ marginwidth=”0″ src=”http://maps.google.co.uk/maps?f=q&source=s_q&hl=en&geocode=&q=manchester&aq=&sll=53.41654,-2.236788&sspn=0.033864,0.090294&ie=UTF8&hq=&hnear=Manchester&t=h&z=12&ll=53.480712,-2.234376&output=embed“></iframe>
…would become…
<iframe width=”300″ height=”300″ frameborder=”0″ scrolling=”no” marginheight=”0″ marginwidth=”0″ src=”http://maps.google.co.uk/maps?f=q&source=s_q&hl=en&geocode=&q=manchester&aq=&sll=53.41654,-2.236788&sspn=0.033864,0.090294&ie=UTF8&hq=&hnear=Manchester&t=h&z=12&ll=53.480712,-2.234376&output=embed&iwloc=near“></iframe>
Thanks to John below for pointing this out
Old information:
Google have tweaked things again. Here is the latest way (March 2009) to embed a map including a location pin without the annoying info window or info bubble showing above it and ruining the maps centre location.
This is particularly important if you are using a small sized map less than around 400px square.
1. Go to google maps or google maps uk
2. Do a search to find (and pin) the location you want to embed a map of.
3. Click the text link, which you will find top right of the main map.
4. Click Customise and preview embedded map
5. Change the dimensions of the map as required and drag the pin to the centre of the map using your mouse.
6. Copy the embed code.
5. In your embed code find the src of the iframe tag ( <iframe src=”http ) and replace
iwloc=addr
or
iwloc=A
with
iwloc=near
6. Stick the embed code into your website and marvel at seeing a pin but no info window.
Before view:
Before iframe code:
<iframe width=”300″ height=”300″ frameborder=”0″ scrolling=”no” marginheight=”0″ marginwidth=”0″ src=”http://maps.google.co.uk/maps?f=q&source=s_q&hl=en&geocode=&q=manchester&sll=53.800651,-4.064941&sspn=21.613333,29.619141&ie=UTF8&t=h&ll=53.492131,-2.228851&spn=0.122552,0.205994&z=11&iwloc=A&output=embed”></iframe>
After view:
After iframe code:
<iframe width=”300″ height=”300″ frameborder=”0″ scrolling=”no” marginheight=”0″ marginwidth=”0″ src=”http://maps.google.co.uk/maps?f=q&source=s_q&hl=en&geocode=&q=manchester&sll=53.800651,-4.064941&sspn=21.613333,29.619141&ie=UTF8&t=h&ll=53.492131,-2.228851&spn=0.122552,0.205994&z=11&iwloc=near&output=embed”></iframe>
I was just looking at this board for the info. Not sure if google has changed anything, but the map code doesn’t seem to include the iwloc anymore as I was trying to make changes and cannot find the code:
View Larger Map
if anyone has some tips, i would absolutely appreciate your help!
copy this to end of the code
&iwloc=near
before: …..output=embed”>
After paste: …output=embed&iwloc=near”>
Works well
Just what I was looking for! Thanks a lot!