Suppose I have a Jquery Object $('.class0 .class1 .class2...'). I want to check if a class .classX is in this object. How can I do this? I don’t think inArray() is not adapted
In the same time, just to make things clearer for me, if I have a Jquery Object $('.class0, .class1, .class2, ...') if I want to check if a class .classX is in this object, I should use inArray() method, right?
Use
.hasClass().Notice there no dot (
.) character prefixingclassX.