a:link {color:#FF0000} /* unvisited link */
a:visited {color:#00FF00} /* visited link */
a:hover {color:#FF00FF} /* mouse over link */
a:active {color:#0000FF} /* se
It wouldn't require jQuery, but it's sure easy to do with jQuery.
$("a").click(function () {
$("a").css("color", "blue");
$(this).css("color", "yellow");
});
You don't need Javascript. The CSS pseudo-class that you're looking for is 'focus'.
ps: it holds the 'last clicked' color only until you click on something else in the page.
a:link {color:#FF0000}
a:visited {color:#00FF00}
a:hover {color:#FF00FF}
a:active {color:#0000FF}
a:focus {color:#0000FF}
<b><a href="#">link 1</a>
<a href="#">link 2</a>
<a href="#">link 3</a>
<a href="#">link 4</a>
<a href="#">link 5</a></b>
You definitely can't do it with css.
With jQuery you could do something like
$("a").live("click", function() {
$("a").removeClass("yourHighlightClass");
$(this).addClass("yourHighlightClass");
});