jquery - trying to remove a class when image is clicked -


i'm try remove class jquery when image clicked can seem work. i'm using

 $(this).removeclass('.title'); 

to remove class it's not working.

 .title{    font-size: 100%;    top: -40px;    color: white;    left: 0%;    position: absolute;      z-index: 1;    } 

here's jsfiddle.

its not

$(this).removeclass('.title'); 

its

$(this).removeclass('title'); 

you must not use . when you're using addclass , removeclass , toggleclass. , metioned other answerers, in demo, class title not applied li, div. must remove title :

$(this).find("div").removeclass('title'); 

demo : http://jsfiddle.net/hungerpain/xyzzx/39/


Comments

Popular posts from this blog

curl - PHP fsockopen help required -

HTTP/1.0 407 Proxy Authentication Required PHP -

c# - Resource not found error -