<html> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <style> .out{width:80px;height:40px;border:1px solid #CCC;background-color:#FFF;} .move{width:80px;height:40px;border:1px solid #CCC;background-color:red;} </style> </head> <body> <input type="button" class="out" onmousemove="this.className='move'" onmouseout="this.className='out'" value="鼠标悬停" /> </body> </html>
示例:
原创文章,转载请注明: 转载自HSBLOG
本文链接地址: CSS input按钮 鼠标悬停改变颜色