日期:2014-05-16 浏览次数:20389 次
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
</head>
<body>
<style>
.r{
margin:150px;
height:100px;
width:100px;
}
@-webkit-keyframes t-r {
25% { -webkit-transform: rotate(-10deg); }
75% { -webkit-transform: rotate(10deg); }
100% { -webkit-transform: rotate(0deg); }
}
@-moz-keyframes t-r {
25% { -moz-transform: rotate(-10deg); }
75% { -moz-transform: rotate(10deg); }
100% { -moz-transform: rotate(0deg); }
}
@-ms-keyframes t-r {
25% { transform: rotate(-10deg); }
75% { transform: rotate(10deg); }
100% { transform: rotate(0deg); }
}
.r img:hover{
border:1px solid #ccc;
-webkit-animation-name: t-r ;
-webkit-animation-duration: 0.3s;
-webkit-animation-iteration-count: 1;
-webkit-transition-timing-function: ease-in-out;
-moz-animation-name:t-r ;
-moz-animation-duration: 0.3s;
-moz-animation-iteration-count: 1;
-moz-transition-timing-function: ease-in-out;
animation-name:t-r;
animation-duration: 0.3s;
animation-iteration-count: 1;
transition-timing-function: ease-in-out;
}
.r img{
border:1px solid #ccc;
height:100px;
width:100px;
}
</style>
<div class="r" >
<img src="http://www.google.com.hk/images/srpr/logo4w.png">
</div>
</body>
</html>