检查后我实现了下面的代码,但效果没有发生,不知道它缺少哪里..
<style>
.rotate {
-webkit-transition: -webkit-transform 0.4s ease-in-out;
-moz-transition: -moz-transform 0.4s ease-in-out;
-o-transition: -o-transform 0.4s ease-in-out;
-ms-transition: -ms-transform 0.4s ease-in-out;
transition: transform 0.4s ease-in-out;
cursor:pointer;
}
.rotate:hover {
color:#afafaf;
-webkit-transform: rotateZ(360deg);
-moz-transform: rotateZ(360deg);
-ms-transform: rotateZ(360deg);
-o-transform: rotateZ(360deg);
transform: rotateZ(360deg);
}
</style>
HTML
<div class="col-lg-6 col-md-6 col-sm-12">
<h2 align="center"><a href="abc.php" class="rotate"> <icon class="icon icon-rocket icon-2x "> </icon> </a> <br />
Build your Resume </h2>
</div>
编辑:将旋转类从图标更改为父级