Skip to content

Instantly share code, notes, and snippets.

@cohitre
Created March 28, 2009 20:36
Show Gist options
  • Save cohitre/87196 to your computer and use it in GitHub Desktop.
Save cohitre/87196 to your computer and use it in GitHub Desktop.
jQuery.fn.fadeOnClick = function( item ) {
this.click(function(){
$("#home").children().fadeOut( 200 );
setTimeout( function(){
$(item).fadeIn();
} , 200 );
});
return this;
}
// $("#pagination li a").unbind("click");
$("#homeLink").fadeOnClick("#innerHome");
$("#servicesLink").fadeOnClick("#networks");
$("#contactLink").fadeOnClick("#contact");
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment