Archived topic
How to make text link in widgets change to italics when highlighted
10 replies · Started by CRISTO on December 20, 2019
On my site all the links change to italic when highlighted, thanks to the nifty little bit of css you gave me...I think this is it:
.site-content a:hover {
font-style: italic;
} .
I would like to do the same thing with the text links in my widgets so that everything is uniform.
Hi there,
Edit your code this:
.site-content a:hover, .footer-widgets a:hover {
font-style: italic;
}
Let me know if this helps :)
Thanks, Leo
Doesn't seem to do it....cleared my cache. Changes to underline on hover (which is great), but no italics.
Hi there,
where did you add the CSS Leo provided?
Can you add it back in so we can take a look.
Hi David,
I added it using GP's simple css. Added at the bottom of the list of css. That's about all I know about css.
By the way, the sidebar widgets do change to italics....just not the footer widgets.
Can you try placing it at the top of the CSS list ?
Idid...and it works! Don't understand why, but I will take it. Thanks, David.
It means you have an error somewhere else in your CSS... this is the problem:
.main-navigation:not(.is_stuck) .sticky-brand {
display: none;
remove_action('generate_after_header', 'generate_add_navigation_after_header', 5);
add_action('generate_after_header_content', function() {
generate_navigation_position();
}
);
.woocommerce-product-gallery {
display: block !important;
}
The remove_action script is PHP so needs to be removed from there. Replace the code with:
.main-navigation:not(.is_stuck) .sticky-brand {
display: none;
}
.woocommerce-product-gallery {
display: block !important;
}
Thanks...made the changes you suggested.
You're welcome