CSS: link selector
CSS selectors complete reference manual
Definition and Usage
: Link Adds special style to unvisited links.
Note:: link selector already visited links without style.
Tip: Use the: visited selector settings visited pages linked style, : hover selector When hover link style on, : Active selector setting when you click on the link styles.
Browser Support
Figures in the table represent the first browser to support the version number of the property.
选择器 | |||||
---|---|---|---|---|---|
:link | 4.0 | 7.0 | 2.0 | 3.1 | 9.6 |
Related Pages
CSS tutorial: CSS Links
CSS tutorial: CSS Pseudo classes
More examples
Examples
Active, visited, unvisited, or when there are hover on link:
a:link {color:green;}
a:visited {color:green;}
a:hover {color:red;}
a:active {color:yellow;}
a:visited {color:green;}
a:hover {color:red;}
a:active {color:yellow;}
try it"
Examples
Different styles of link style:
a.ex1:hover,a.ex1:active {color:red;}
a.ex2:hover,a.ex2:active {font-size:150%;}
a.ex2:hover,a.ex2:active {font-size:150%;}
try it"