Forum Moderators: not2easy
<head><title></title>
<style type="text/css">
body {
font-family:arial;
}
.sub1 {
background-color:#cccccc;
position:absolute;
margin:0px auto;
padding: 3px 8px 4px 8px;
border: 1px solid #ffffff;
}.sub1 :hover {
background-color:#eeeeee;
}</style>
</head><body>
<div class="sub1"><a href="#">background color change?</a></div>
</body>
</html>
Thanks for any help...
.sub1 a {
display:block;
background: #originalcolor;
}
.sub1 a:hover {
background: #newcolor;
}
You may find that you need to set the a:link, a:active, and a:visited properties also in order for the hover to work. The order must be...
link
visited
hover
active
The reason you need to pu the hover on the <a> tag is that some browsers (IE!) do not recognize hover effects on anything but links.