Created
December 2, 2014 15:55
-
-
Save zetareticoli/1a5dea5b4e68b49a62aa to your computer and use it in GitHub Desktop.
Trigger event click on a button which makes something visible.
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
$('.button').click(function(event){ | |
event.stopPropagation(); | |
event.preventDefault(); | |
$(this).toggleClass("clicked"); | |
$('.element').toggleClass("visible"); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment