At our February meeting, we took pseudo-class selectors to a new level by employing combined declarations and by using classes.
A combined selector looks like this -- a:hover:visited. It would define the hover style of a link after it has been visited.
So in the below example, the link hover will be overlined when not visited, but underlined after being visited:
a:hover {color:red; text-decoration: overline;}
a:hover:visited {color:red; text-decoration: underline;}
Adding a class to a pseudo-class selector will let you apply the styling to specific links, and that will be useful for defining the style of navigation links. The syntax is familiar:
a:link.nav {color:green;} -- the style declaration
<a href="PACS_Home.htm" class="nav"> PACS HOME</a> -- the link that will now have the text color green
We ended by looking at two proposed tags, <nl> and <nav>, which, if either is adopted, will make it easier to define and style navigation links.
No comments:
Post a Comment