I have an anchor text that when click adds an active class to another class. I want to remove it when it has an active class or if I click the anchor text again. How can I do th
try this example
Name1 Name2 Name3 Name4 Name5
this code will be add sector-active class to clicked a tag and remove sector-active class from another a tag
sector-active
a
if you can add sector-active class to all clicked a tag then comment to following line
// $('a').removeClass('sector-active');
this will help you