鼠标hover时图片效果

时间:2024-04-20 16:05:57

<!DOCTYPE html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>image</title>
<style>
div{
width: 200px;
height: 150px;
overflow: hidden;
}
div img{
cursor: pointer;
transition: all 0.6s;
}
div img:hover{

transform: scale(1.2);
}
</style>
</head>

<body style="margin:300px;">

<div>
<img src="http://imgsize.ph.126.net/?imgurl=http://cms-bucket.nosdn.127.net/9c8bf5f5e08a4719a03fe68b498cc28820170416011841.jpeg_140x88x1x85.jpg" width="200px" height="150px"/>
</div>

</body>
</html>