HTML and CSS Certification Practice Test 2025 – The All-in-One Guide to Master Your Certification!

Question: 1 / 400

Which CSS property is used to control the text color of a visited link?

text-color

link-color

color

The correct choice is the property used in CSS to set the text color for various states of links, including visited links. The property itself is called "color," and it defines the color of the text within an HTML element. For links, the text color can be specified for different states using pseudo-classes such as :link, :visited, :hover, and :active.

In the case of visited links, you would use the pseudo-class :visited to alter the text color of links that the user has already clicked on. Therefore, to change the text color of a visited link, you would write a CSS rule like this:

```css

a:visited {

color: purple; /* Or any other color you want */

}

```

This ensures that the styling accurately reflects the state of the link in question. The other options do not represent valid CSS properties, making them incorrect for controlling the text color of a visited link.

Get further explanation with Examzify DeepDiveBeta

visited-color

Next Question

Report this question

Subscribe

Get the latest from Examzify

You can unsubscribe at any time. Read our privacy policy