Here is the jQuery I'm using:
jQuery(document).ready(function () {
jQuery(".controller a").click(function () {
jQuery(this).parents('.slider').toggleClass('sliderclick');
jQuery(this).parents('.slider').animate({left:'0px'},1000);
jQuery(this).parents('.sliderclick').animate({left:'-200px'},1000);
return false;
});
});
In the jsfiddle, it works perfectly but when I tried it on my localhost, it first toggles when first click and after then it get works perfectly. If I use toggle() function it amazingly hides say toggles the a. How can I do?