Summary
The :any-link CSS pseudo-class represents an element that acts as the source anchor of a hyperlink independent of whether it has been visited, that is, it matches every <a>, <area> or <link> elements with an href attribute. So, it matches all elements that match :link or :visited.
Syntax
:any-link( style properties ) { style properties }
Example
:any-link {
color: green;
font-weight: bold;
}
<a href="https://mozilla.org">Different page</a> <a href="#">Anchor</a> <map name="primary"> <area shape="circle" coords="50,50,25" href="another.html" /> <area shape="default" nohref /> </map>
Specifications
| Specification | Status | Comment |
|---|---|---|
| Selectors Level 4 The definition of ':any-link' in that specification. |
Working Draft | Initial definition |
Browser compatibility
| Feature | Chrome | Firefox (Gecko) | Internet Explorer | Opera | Safari |
|---|---|---|---|---|---|
| Basic support | ? | (Yes)-moz 50.0 (50.0) |
? | ? | ? |
| Feature | Android | Firefox Mobile (Gecko) | IE Mobile | Opera Mobile | Safari Mobile |
|---|---|---|---|---|---|
| Basic support | ? | (Yes)-moz 50.0 (50.0) |
? | ? | ? |
Document Tags and Contributors
Tags:
Contributors to this page:
Sebastianz
Last updated by:
Sebastianz,