jQuery plugin. Unobtrusively load interactive Google maps on top of static JPEG Google maps.
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.


--~~ Unobtrusive Google Maps ~~--

	Loads interactive Google maps when a static JPEG map
	is clicked. The static map is replaced with a div. The
	div is filled with a regular interactive Google map.
        Demo: http://f.augustl.com/2011/unobtrusive_google_maps/
--~~ Usage ~~--

	Download the javascript: http://github.com/augustl/unobtrusive-google-maps/raw/master/unobtrusive-google-maps.jquery.js
	Include the javascript on your page.

	In your HTML (without the line break slashes):

<img src="http://maps.google.com/staticmap?center=40.714728,-73.998672\
&sensor=false" class="static_map" />

	In your javascripts:

--~~ Why? ~~--

	You want your page to load fast. So you use static maps. You
	don't need dynamic and interactive maps until a user actually
	clicks the map, and loading the entire Google maps stack when
	your page loads makes your page slower. What if the user didn't
	want to click your Google map at all? He just spent all that
	time loading Google maps for nothing.