I have the following piece of code:
if((String(parent).length > 0) && (String(this.className).length > 0)) {
where this.className contains the value “top currentMenu”
Using this.className name, I need a means of removing from this.className, “currentMenu” ONLY using jQuery, so that the end result for this.className is just “top”.
It is simply:
Reference:
.removeClassIn plain JavaScript you can do something like:
Or I don’t understand your problem 🙂