Set colors of hypertext for blog
-
My theme (VENI) does not give me the option to select colors for hyperlinks within my blog posts. I do not want to change the color of my blog name or the color of the post titles. But currently, when I link to a source outside the blog, I have to set the color of the link (to let the reader know there is a link there!) with html and I must do this for very link and every blog post.
The benefit of CSS is that you are supposed to be able to do this once.
I cannot figure out where in the CSS customizer to plug in the code.
link: #0000FF;
visited: #008000;
hover: #ff00ff;
active: #ff0000;Any suggestions would be velcome
The blog I need help with is: (visible only to logged in users)
-
Hi there,
To add custom CSS
Select Appearance > Customize > CSS from your Admin Dashboard and enter the custom CSS there.
Try adding the following line of CSS:
.entry-content a { color: #0000ff; }Let me know how this works out for you.
-
Thanks for your suggestion. No luck. I was not sure where to put the CSS in the custom box so I tried putting it everywhere. Not at once, one at a time. Nothing worked.
. What follows in black type is what I have in my box now. “The add it here” refers to were I tried adding your suggested line of CSS. It did not work
.entry-content a {
color: #ff00d4; (Changed the color to hot pink to be sure I would not miss it.)
}I also tried
.entry-content a {
link: #0000FF;
visited: #008000;
hover: #ff00ff;
active: #ff0000;}
What I have in the CSS box now
.site-content {
}Add it HERE?
.site-header a {
font-size: 60pt;
color: #800000;
text-shadow: 2px 2px;
text-shadow: 2px 2px;
}Add it HERE?
body {
font-size: 12pt;
font-family: Noto-Sans;
color: #000000;
line-height: 14pt;
padding-left: 1pt;
padding-right: 10pt;
padding-top: 5pt;
}Add it HERE?
h1 {
font-family: Noto-Sans;
color: #000000;
text-shadow: 2px 2px;
text-shadow: 2px 2px;
}
Add it HERE?h2 {
font-family: Noto-Sans;
color: #000000;
}Add it HERE?
-
Hi @ornamento ,
I’m sorry to hear this isn’t working smoothly for you…
I went and added the code @g471n provided and it worked for me. (Thanks @g471n ! :) ) I then went and added the CSS you said you already have and added @g471n ‘s code. And I found it still worked. So I think there is something else at play here…
Could you let us know what code you currently use in your HTML (from the post editor) to get the color change? I was looking at your code and noticed your links have the color stated inside the tag and also as a separate <span> tag surrounding each link. If the tag and its element is all that is in the <span> tag, then the color styling in the is sufficient and you shouldn’t need the <span> tag.
If you delete the <span> tag, does the CSS given above take effect? (It shouldn’t matter really where you insert the CSS, but go ahead and just add it to the very bottom of the other CSS you already have.)
I hope this information gets us closer to your solution… :)
-
Oops… Let me try that middle paragraph again…
Could you let us know what code you currently use in your HTML (from the post editor) to get the color change? I was looking at your code and noticed your links have the color stated inside the
<a>tag and also as a separate<span>tag surrounding each link. If the<a>tag and its element is all that is in the<span>tag, then the color styling in the<a>tag is sufficient and you shouldn’t need the<span>tag. -
Hi ornamento
The HTML and CSS that you have been using when you write the post will override the CSS from the theme template and the CSS customizer.
Try creating a new post without your additional HTML to set the link color.
The link should display in the color you have set with the CSS in the customizer
- The topic ‘Set colors of hypertext for blog’ is closed to new replies.