- This topic has 5 replies, 3 voices, and was last updated 2 years, 11 months ago by
David.
-
AuthorPosts
-
March 31, 2023 at 10:23 am #2590999
Jennifer
I have certain blocks where I want to highlight the colour of a visited link.
For those blocks, I have added an additional class in Advanced called “daily-readings-links”.
In Additional CSS I have added:
.daily-readings-links a:visited {
color: #E31C3D;
}This works as intended if I click on the link on the page that contains the block; the visited link turns red and stays red if I leave and return. However, if I visit the page that the link points to some other way and then go look at the link, it is still the original colour.
Is there a way to have the link change colour no matter how the page (that the link points to) was visited?
Edit: There is no option in Appearance > Customize > Colours > Body (or Content) to add a visited link colour, only Initial and Hover.
March 31, 2023 at 11:54 am #2591132Ying
StaffCustomer SupportHi Jennifer,
However, if I visit the page that the link points to some other way and then go look at the link,
Not sure I understand what this means.
The CSS you are using is the correct way to change the visited link color.
I’m not aware of other CSS for this.March 31, 2023 at 7:22 pm #2591445Jennifer
I was under the impression that the URL for a page would register as ‘visited’ no matter how the page was called up. So you have two pages, as a simple example, with the same link for a third page. I follow one link. On both pages the URL would show as ‘visited’. Perhaps I’m crazy and this doesn’t happen? Only one page would show the URL as ‘visited’?
Edit: other than the blocks where I have specified a colour for visited links (and I have clicked directly from this page), no link on the site shows a different colour if the URL has been visited.
April 1, 2023 at 6:04 am #2591913David
StaffCustomer SupportHi there,
the
:visitedpseudo selector only applies to the link if it has been clicked on. As the browser records the visited action on click.And in the theme, we don’t apply a visited color.
If you want you can do some CSS like this:
.entry-content p a:visited { color: #f00; }This will apply a visited style to any links within the content of your post.
April 1, 2023 at 11:27 am #2592283Jennifer
Got it, thanks!
April 1, 2023 at 2:38 pm #2592436David
StaffCustomer SupportYou’re welcome
-
AuthorPosts
- You must be logged in to reply to this topic.