• My homepage is

    https://www.jakobrdl.dk

    and it is based on a child theme of the Twenty Twelve Theme. Until recently, possibly until I updated WordPress and the associated themes, links on my homepage all had the same blue color, whether they had been clicked or not. But now the clicked (or visited) links have a grey color, and I don’t understand why.

    The style.css file of my child theme looks as shown below, and if I change the settings for “a:link” and for “a:hover”, the appearance of the links changes – but nothing in this file seems to change the way visited links appears.

    So are the visited links being overwritten somewhere? If yes, where? Or is there another explanation?

    Thanks in advance for the help.

    /*
    Theme Name:     Twenty Twelve Child
    Theme URI:      https://jakobrdl.dk/
    Description:    Child theme for the Twenty Twelve theme
    Author:         Jakob Rosenkrantz de Lasson
    Author URI:     https://jakobrdl.dk/
    Template:       twentytwelve
    Version:        1.0.0
    */
    
    @import url("../twentytwelve/style.css");
    
    a:link {
        color: rgb(10,57,165);
        text-decoration: none;
    }
    
    a:visited {
        color: rgb(10,57,165);
        text-decoration: none;
    }
    
    a:hover {
        color: rgb(10,57,165);
        border-bottom: 1px dotted;
    }
    
    a:active {
        color: rgb(10,57,165);
        border-style: none;
        text-decoration: none;
    }
    
    <style type="text/css">
    #wrap {
       width:100%;
       margin:0 auto;
    }
    #left_col {
       float:left;
       width:70%;
    }
    #cen_col {
       float:left;
       width:10%;
    }
    #right_col {
       float:right;
       width:20%;
    }
    </style>
Viewing 4 replies - 1 through 4 (of 4 total)
  • Line 801 of the twentywelve style.css has this:

    ‘.entry-content a:visited, .comment-content a:visited {
    color: #9F9F9F;
    }’

    So you can add that your child, using the correct color.

    Thread Starter jakobrosenkrantz

    (@jakobrosenkrantz)

    Thanks, jrav001, that solved the problem!

    What puzzles me, however, is why “a:link” and “a:hover” could be set as indicated in my first post, while this same code did not work for “a:visited”; do you have an explanation for that?

    I am having the same issue since TwentyTwelve updated. I just set up a TwentyTwelve-child theme and tried to reset the colors of the links. But the base color (a:link)and hover (a:hover) works correctly, but the visited (a:visited) stays the same ugly and illegible gray (I hate gray text – poor accessibility and poor usability). The only thing different is I am using hex code and not rgb. I’ll try RGB next. Ugh!

    That did not work.

    See https://mainecla.org/

    Very frustrated…

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Visited links don't have the expected color’ is closed to new replies.