JQuery addClass to a tag problem?

Try this: $('navlist li#tabItem' + currentTab + ' a'). AddClass('navlistHover'); The :has() selector selects items that have the a element as children: docs.jquery.com/Selectors/has.

That'll add the navListHover to the anchor tag, not to the LI which is what he is looking to do. – Parrots Jan 14 '10 at 14:24 That's not how I interpreted the question. – Will Vousden Jan 14 '10 at 14:25 He does say: 'I want to add a class to the a element' – Tom van Enckevort Jan 14 '10 at 14:26 Apologies, I misread the question.

– Parrots Jan 14 '10 at 14:52.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions