sf.html
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>图片缩放</title>
<link rel="stylesheet" type="text/css" href="css/sf.css"/>
</head>
<body>
<div class="sf">
<img src="img/003.jpg">
</div>
</body>
</html>
sf.css
.sf img
{
height: 200px;
width: 300px;
}
.sf img:hover
{
transform: scale(1.2);
}