I have a page with a bunch of divs with a roll-over effect using onMouseOver and onMouseOut. I also have an onMouseClick event.
Is there a way to do the roll-overs (and maybe the onClick) that will be viewable in most/all browsers?
I know Mozilla supports the :hover pseudo-class, but i believe they are the only ones.
I'd like to appease the great and wise W3C validator...
Thanks! -dan
Here's what I have so far...
-this creates a opacity roll-over effect that has been successfully tested in IE and Firefox, but should also work in Netscape, Opera, and hopefully Safari.
CSS:
HTML:
Is there a way to do the roll-overs (and maybe the onClick) that will be viewable in most/all browsers?
I know Mozilla supports the :hover pseudo-class, but i believe they are the only ones.
I'd like to appease the great and wise W3C validator...
Thanks! -dan
Here's what I have so far...
-this creates a opacity roll-over effect that has been successfully tested in IE and Firefox, but should also work in Netscape, Opera, and hopefully Safari.
CSS:
Code:
.track {
cursor: pointer;
width: 331px;
height: 16px;
margin: 5px;
font-size: 11px;
text-align: left;
color: #000000;
border: 1px solid dimgray;
padding: 3px;
overflow: hidden;
filter: alpha(opacity=60);
-moz-opacity: 0.6;
opacity: 0.6;
}
HTML:
Code:
<div class="test" onClick="getSimilar(this.innerHTML);" onMouseOver="this.filters.alpha.opacity=99;" onMouseOut="this.filters.alpha.opacity=60;">
test
</div>