The following code (which you can copy and paste as a complete file) works in Gecko browsers and Opera, but not IE.
What I’m trying to achieve is a single hyperlink for which some text underlines when hovered over, but the rest of the text does not (despite being part of the hyperlink). Does anyone know how this can this be achieved in Internet Explorer?
<html>
<head>
<style>
a {
text-decoration: none;
}
a:hover .test2 {
text-decoration: underline;
}
</style>
</head>
<body>
<a href="#"><span class="test2">One</span> Two</a>
</body>
</html>
Many thanks in advance for any help or ideas you can provide.