I am creating a special "hamburger" icon which, when hovered over, changes from transparent with white lines to yellow with black lines. Because I want the lines to change color when you hover over any portion of the box, I assumed that I would need to use jQuery (or at least javascript) to add a class to the icon-bars. I am having trouble figuring out how to do this.
First, here is the HTML I'm trying to manipulate:
I currently have a function within the $(document).ready function to toggle adding/removing a class that would make the lines black. In my CSS file, I created a class (blk-icon-bar) which sets the background color to black:
And here is the JQuery function I'm trying to use:
I added an alert within the hover function to ensure that I was getting into the function and the alert does appear but, none of the lines change color. What am I doing wrong with this code? Any and all help would be greatly appreciated.
Chris