Can I set link attributes -hover and visited - inside a link tag for example:
<A HREF='http://www.webdeveloper.com/forum/archive/index.php/something.htm' STYLE='hover:Underline;'>
well the above didn't work for me. is there another way?
Thanks.Sorry, but it's impossible. You could do it with JavaScript, but it probably wouldn't be worth it Thanks.can i ask why you may want to do this anyway? one of the great things about css is that you only have to update one linked stylesheet and all of your pages are updated, adding the styles individually into each link would be such a pain in the butt!!!
All I can think at the moment what your trying to do is have different links have different colours when they are hovered. This is possible if thats the case. Just create a different class in your stylesheet for each type, then in the body give each link its class.Give the link a class...
<a href=http://www.webdeveloper.com/forum/archive/index.php/"link.html" class=special>link text</a>
...and in your style section or stylesheet include...
a.special {
// attributes common to all "special" links here
}
a.special:visited {
// attributes unique to visited "special" links
}
a.special:hover, a.special:active {
// attributes unique to "special" hover and active links
}
<A HREF='http://www.webdeveloper.com/forum/archive/index.php/something.htm' STYLE='hover:Underline;'>
well the above didn't work for me. is there another way?
Thanks.Sorry, but it's impossible. You could do it with JavaScript, but it probably wouldn't be worth it Thanks.can i ask why you may want to do this anyway? one of the great things about css is that you only have to update one linked stylesheet and all of your pages are updated, adding the styles individually into each link would be such a pain in the butt!!!
All I can think at the moment what your trying to do is have different links have different colours when they are hovered. This is possible if thats the case. Just create a different class in your stylesheet for each type, then in the body give each link its class.Give the link a class...
<a href=http://www.webdeveloper.com/forum/archive/index.php/"link.html" class=special>link text</a>
...and in your style section or stylesheet include...
a.special {
// attributes common to all "special" links here
}
a.special:visited {
// attributes unique to visited "special" links
}
a.special:hover, a.special:active {
// attributes unique to "special" hover and active links
}