From Web Education Community Group
< CSS‎ | Selectors
Revision as of 18:56, 21 November 2011 by Rworth (Talk | contribs)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Pseudo-classes :target

The :target pseudo-class represents an element that is the target element of the referring URI.


:target{ properties }



 a:link, a:visited{
   color: red;
   content: "Here. ";


  <p><a href="#target1">Go to down!</a></p>
  <p id="target1">target1</p>

Css3 selectors target be.png

Css3 selectors target af.png

CSS defines the :target pseudo-class in 6.6.2. The target pseudo-class :target.