Jump to content

onmouseover


dandrews

Recommended Posts

I am using the code given at http://www.w3schools.com/css/css_image_transparency.aspto make buttons switch opacity as you mouseover them. Here is the code:

<img src="klematis.jpg" width="150" height="113" alt="klematis"style="-moz-opacity:0.4;filter:alpha(opacity=40)"onmouseover="this.style.MozOpacity=1;this.filters.alpha.opacity=100"onmouseout="this.style.MozOpacity=0.4;this.filters.alpha.opacity=40" />

This works fine and I have it written inline at each button.My question is, how much of this code could be relegated to the style sheet? The 'style=' could go, but what about onmouseover and onmouseout? Can they go too, and how would I write it?thanks

Link to comment
Share on other sites

Can't help you, but can I recomed you place this in JavaScript tutorial?

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...