Use mouse in/out action to trigger the style change
|
|
<html> <head> <title>Style Example</title> </head> <body> <P>Move your mouse over the square.</p> <div id="div1" style="background-color: red; height: 50px; width: 50px" onmouseover="this.style.backgroundColor = 'blue'" onmouseout="this.style.backgroundColor = 'red'"> </div> </body> </html>
|
|
|
HTML code for linking to this page:
Related in same category :
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
|