Skip to content

Instantly share code, notes, and snippets.

@RuiSantosdotme
Created August 20, 2014 13:00
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 RuiSantosdotme/8a782419a55967732e1e to your computer and use it in GitHub Desktop.
Save RuiSantosdotme/8a782419a55967732e1e to your computer and use it in GitHub Desktop.
<script type="text/javascript">
$(document).ready(function(){
$( ".navicon" ).click(function() {
$( "#menu" ).slideToggle( "medium", function() {
// Animation complete.
});
});
});
$(document).ready(function(){
$('.navicon').toggle(function () {
$("body").css({"overflow": "hidden !important"});
$("#mobile_menu").css({"width": "100% !important"});
});
});
</script>
$('.myclass').click(function() {
if ($(this).hasClass('toggle')) {
doThis;
$(this).removeClass('toggle');
} else {
doThis;
$(this).addClass('toggle');
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment