Mobile app version of vmapp.org
Login or Join
Gloria169

: Prevent font color from changing when hovering over child menu item I'm baffling myself with this one. I have a main menu set up and when you hover over a menu item the background-color is

@Gloria169

Posted in: #Css #Css3

I'm baffling myself with this one.

I have a main menu set up and when you hover over a menu item the background-color is #f2dabd and the color is #8d0000 , however when i hover over a parent menu item, the dropdown appears as expected, but if i then hover over a child item the parent menu title font colour changes (the parent item is neither :active or :hover but the hover background color still applies. I cannot seem to figure out how to prevent it from doing this.

Its a little hard to explain so I will provide a link to the development site in question:

Ok so if you hover over the menu item Services then without clicking, hover over one of the child items such as Restoration, you will see that the 'Services' text changes colour to match the hover background color. I just can't seem to figure out how to target it with css?

Any advise would be most appreciated. I had asked this in the Joomla specific exchange, and received an answer - but the answer no longer seems to work, thus as it isnt Joomla specific, I am asking this here.

Regards D

10.01% popularity Vote Up Vote Down


Login to follow query

More posts by @Gloria169

1 Comments

Sorted by latest first Latest Oldest Best

 

@Harper822

The over the li is what causing the problem.

So when you hover over the span the color changes but when you hover over the li only the background-color changes .

To resolve the problem you need to change the color of the span when you hover over the li.

.zen-menu-horizontal ul li:hover > span {
color: #666 ;
}

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme