Skip to content

Instantly share code, notes, and snippets.

@krukid
Created December 28, 2010 00:18
Show Gist options
  • Save krukid/756726 to your computer and use it in GitHub Desktop.
Save krukid/756726 to your computer and use it in GitHub Desktop.
Anchor: selective underline CSS
<!DOCTYPE html>
<html>
<head>
<title>Anchor: selective underline CSS</title>
<style type="text/css">
.a {
text-decoration:none;
font-size: 40px;
}
.w {
}
.t {
background: lime;
}
.b {
background: #fcc;
}
.w:hover .b {
text-decoration: underline;
color: red;
}
</style>
</head>
<body>
<a class="a" href="/krUkid">
<span class="w">
<span class="t">58</span>
<span class="b">answers</span>
</span>
</a>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment