I am endeavoring to incorporate an icon into all unvisited links on a specific Wordpress category page.
Below is the CSS code that I am utilizing. It has been placed at the conclusion of my final CSS file.
.category-xyzzy .entry-title a:link {
background-image: url("/new-star.png");
background-repeat: no-repeat;
color: pink;
}
.category-xyzzy .entry-title a:visited {
background: none;
}
An unexpected occurrence is the background image being added to all links, whether visited or not, while the pink color is only applied to the unvisited links.
This anomaly persists across different browsers.
The fact that exclusively the unvisited links are displaying in pink seems to suggest that the initial selector is functioning correctly. However, I am puzzled as to why the background image, included within the same CSS rule and nowhere else, is being assigned to all links.
In order to troubleshoot, I introduced the second rule matching against a:visited with the hope of resolving the issue. Nonetheless, the problem prevails regardless of whether the second rule is specified or not.