3月15日作业
实例
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title>绕口令</title> <style type="text/css"> div{ width: 400px; height: 250px; padding: 15px; /*background-image: url(image/66.jpg);*/ background-size: 430px 280px; background-repeat: no-repeat; border-radius: 20px; box-shadow: 6px 6px 6px #888; } .text{ color: $363636; line-height: 1.5em; text-indent: 2em; } </style> </head> <body> <div> <h3 style="color: brown;text-align: center;font-size: 20px;" onmouseover="change(this)" onmouseout="old(this)">(绕口令)漆匠与锡匠</h3> <p class="text">七巷一个漆匠,西巷一个锡匠。七巷漆匠用了西巷锡匠的锡,西巷锡匠拿了七巷漆匠的漆,七巷漆匠气西巷锡匠用了漆,西巷锡匠讥七巷漆匠拿了锡。</p> </div> <script type="text/javascript"> function change(element){ element.style.fontSize = '24px' element.style.color = 'green' } function old(element){ element.style.fontSize = '20px' element.style.color = 'brown' } </script> </body> </html>
运行实例 »
点击 "运行实例" 按钮查看在线实例