Underline for active menupoint won't change colour with custom CSS
-
Hi Armin and Marius,
I am working on a home page for a website where the menu text is white instead of black as it is on all other pages. I followed your instructions in Documentation 'CSS based on current page', but the underline for the active menu point is still showing as black, not white. I have tried several times to fix but nothing works.
Here is the page: http://originalprojects.co.uk/category/now/ ...you will see Now is still underlined in black, but I want it to be white. I am using Chrome.
This is the code I have in custom CSS:
/* navigation /
body.slug-now nav.primary a{
color: white;
}
/ navigation /
body.slug-now nav.primary a{
color: white;
}
/ navigation mouseover /
body.slug-now nav.primary a:hover{
color: white;
}
/ navigation mouseover underline color /
body.slug-now nav.primary a:hover span{
border-bottom-color: white;
}
/ navigation transition */
nav.primary a{
transition: all 600ms ease;
-moz-transition: 600ms ease;
-o-transition: 600ms ease;
-webkit-transition: all 600ms ease;
}Could you please advise how to fix this?
Thanks very much,
Alida -
Dear @alidarosie
try this:
nav.laynav .current-menu-item>a span { border-bottom-color: white; }Best!
Marius -
@mariusjopen said in Underline for active menupoint won't change colour with custom CSS:
nav.laynav .current-menu-item>a span {
border-bottom-color: white;
}Thank you so much Marius, that is perfect! For anyone else with the same issue, I just had to add body.slug-page-title in front of this to point it to apply to a specific pages. All the best, Alida
-
-
Y yanekblue referenced this topic on
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login