E:link / E:visited

The :link pseudo-class applies to links that have not yet been visited. The :visited pseudo-class applies once the link has been visited by the user. (Source:W3C)


  1. <p><a href="http://w3.org">Link to the W3C website</a></p>


  1. a:link{color:green;text-decoration:underline}
  2. a:visited{color:red}


Link to the W3C website

In the example, the link should be green and underlined unless you've already been to the W3C's web site, in which case the link will be red.