If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below.

Enjoy an ad free experience by logging in. Not a member yet? Register.

Using addClass() function with live()

I am trying to use the .live() jQuery function in cooperation with the .addClass() function, but I am unsure of how exactly to pass the parameter of the class-to-be-added's name through the live() function to work with addClass().

I would like to use addClass() in both instances in the code above in cooperation with live() while being able to pass the class's name through the live() function. I've searched around the web quite a bit, but none of my searches have resulted in an answer that fits my specific needs.

Users who have thanked oVTech for this post:

I apologize, but after reevaluating my logic I realized that using click() with live(), as I was already doing, was enough to make addClass() operate as though it was being used with live() itself. The problem arose in my specific case where the CSS background color was not changing due to an external influence.

I was able to resolve the problem without needing an answer to this one. Thank you for your help, though, oVTech.