Created
September 4, 2008 15:38
-
-
Save 53cr/8791 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// showcase viewer | |
$(document).ready(function(){ | |
$("div#showcase ul li a").act_as_showcase(); | |
googlemap(); | |
}); | |
// showcase | |
(function($) | |
{ | |
$.fn.act_as_showcase = function() | |
{ | |
act_as_showcase = function(event) | |
{ | |
event.preventDefault(); | |
var img = new Image(); | |
$('#viewer img').remove(); | |
$('#viewer').addClass('loading'); | |
$(img).load(function(){ | |
$(img).hide(); | |
$('#viewer').removeClass('loading').append(this); | |
$(img).fadeIn('slow'); | |
}).attr('src',this); | |
}; | |
this.click(act_as_showcase); | |
}; | |
})(jQuery); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment