Archived topic
Exclude Footer Bold/Underline Link CSS
7 replies · Started by Kevin on January 8, 2023
I am going to update all my links to bold/underline with the following:
a {
text-underline-offset: .45em;
}
#content a {
font-weight: bold !important;
}
I wanted to know how can I exclude the footer? In fact I just want the bold/underline in articles/posts and no where else so if there is way to structure it that way please let me know.
Hi there,
if you want it to apply only to the content of the single post then you can use:
.entry-content a {
text-underline-offset: .45em;
}
.entry-content a {
font-weight: bold !important;
}
This only applies to the single post/page content, it won't affect header, footer, sidebars or any content that is hooked in.
Thank you! Is there a way to exclude header and footer from the underline option in the customizer? Basically I'm just looking to have content links in pages and posts bolded and underlined and no where else.
In that case, disable the links in the Customizer.
And add them all via CSS eg.
.entry-content a {
text-decoration: underline;
text-decoration-color: #f00;
text-underline-offset: .45em;
font-weight: bold;
}
.entry-content a:hover {
/* add the link hover styles */
}
Let us know if that works for you, and if you need assist with the correct static and hover styles CSS.
Ok thanks
You're welcome, let us know if you need the CSS for your specific style needs.
Got it all figured out, very much appreciate the help!
Glad to hear that!