EN
Данное содержимое не доступно на вашем языке, используйте версию на английском языке.

:visited pseudo-class

Specifies the style of an a element if the link has been visited recently.

CSS 2.1, Section 5.11.2

 

Syntax

selector:visited {...}

Parameters

selector

A CSS simple selector.

Standards information

Remarks

:visited is often used with :active, :hover, and :link, which are the pseudo-classes that reflect the other states of a link.

The default value of the :visited pseudo-class varies by browser, as does the amount of time used to define a recent visit.

Windows Internet Explorer 8. For security reasons, :visited is not supported by querySelector or querySelectorAll; for more information, see Selecting Objects with JavaScript.

Examples

The following style rule uses :visited to set the color attribute of visited links in a document.


<style>
    A:visited { color:blue } 
</style>

 

 

Показ:
© 2014 Microsoft