Skip to content

Instantly share code, notes, and snippets.

@mrnugget
Created November 14, 2011 18:20
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mrnugget/1364674 to your computer and use it in GitHub Desktop.
Save mrnugget/1364674 to your computer and use it in GitHub Desktop.
$(function() {
$(".session li.file").each(function() {
elem = $(this).children(".file-info");
$(this).click(function() {
if($(this).hasClass("file-active"))
{
$(this).removeClass("file-active")
} else {
$(this).addClass("file-active")
}
if(elem.hasClass("hidden")) {
elem.removeClass("hidden");
} else { elem.addClass("hidden"); }
});
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment