My jquery does not work. Some symbol seems to be missing and I have no clue what -
dreamweaver , jsfiddle keeps telling me there error in code. missing? semicolon? brackets? im confused!
if(jquery('.home').data('clicked')) { $(this).toggleclass("item-active"); $(".block-1").toggleclass("blocks"); $(".b1").toggleclass("blockss"); $(".content").addclass("content-removed"); $(".block-2").removeclass("blocks"); $(".b2").removeclass("blockss"); $(".products").removeclass("item-active"); }); } else { $(".content").removeclass("content-removed"); }
updated:
if($('.home').data('clicked')) { $(this).toggleclass("item-active"); $(".block-1").toggleclass("blocks"); $(".b1").toggleclass("blockss"); $(".content").addclass("content-removed"); $(".block-2").removeclass("blocks"); $(".b2").removeclass("blockss"); $(".products").removeclass("item-active"); } else { $(".content").removeclass("content-removed"); }
remove the
});
before } else {
jquery
No comments:
Post a Comment