How to add and remove css classes to an element using jquery?
Answer / Rajnish Mohan Saxena
To add a class, use the `addClass()` method: `$('.selector').addClass('myClass');`. To remove a class, use the `removeClass()` method: `$('.selector').removeClass('myClass');`
| Is This Answer Correct ? | 0 Yes | 0 No |
How to read cookies in jquery?
How to get the style property of an element using ?
What is the use of jQuery filter?
Explain the difference between .js and .min.js?
Is it too early to discuss jquery ui 1.8?
How to search for descendant elements that match the specified selectors using ?
What are the advantage of using minimized version of jquery?
How can events be prevented from stopping to work after an ajax request?
Difference Between Prop and Attr in jQuery?
Explain the script build up by jquery?
What is the difference between $('div') and $('<div/>') in jQuery?
How do you implement animation functionality?