Tuesday, September 27, 2005

Embedding Panoramio in your site

Some people have asked in the forum for a way to have Panoramio on
their site. So I went for an easier solution for all of you. I just
cooked a mini panoramio version, ready to be used on iframes outside
Panoramio. An example is:



This is what you need to write in your site:

<iframe src="http://www.panoramio.com/plugin.php?
lt=43.406295&amp;ln=-2.686586&amp;z=3&amp;k=1" width="446px" height="300px"></iframe>


You must pass these options as you will do for a GET request, and the
name of these options is lt (for latitude), ln (for longitude), k (for
kind of map, 0 = map, 1 = satellite, 2 = hybrid), z (for zoom level, 0
is the maximum zoom, 17 is the minimum), zm = 1 to activate the zoom with the mouse wheel and user (for the user email).
All of these options are optional.

You can of course tweak the size of this frame using its width and/or
height attributes.

I will improve this mini Panoramio over time, specially so it can show
pictures at a decent size.