I have a link on my website that says "Fullscreen Google Map." As soon as I click on it, I load the google map into a 100% and 100% fixed container div . When I click the link, I also add #map as a hash.
Is it possible for the browser feedback button to work with this? That is, if I click this link, I will add #map to my current address. As soon as I press the back button, the #map hash is deleted and the div container with the google map is deleted or hidden.
How is this possible?
edit:
$('.showMapLink').live('click', function() { $('#mapContainer').fadeIn('fast', function () { loadMap("mapContainer"); top.location.hash = "map"; $(window).bind( 'hashchange', function( event ) { $('#mapContainer').fadeOut('fast', function () { $(this).children().remove(); }) }); }); });
javascript jquery browser-history
matt Mar 21 '11 at 12:03 2011-03-21 12:03
source share