【问题标题】:Image Rotation jquery图像旋转jQuery
【发布时间】:2023-03-13 03:57:01
【问题描述】:

我正在寻找一种使用 jquery 创建图像旋转的方法。我必须为四个带有过渡的图像制作动画。此效果必须顺时针工作。

现在我有一个链接: http://www.artega.de/

这些示例如何工作?

PS:对不起我的英语不好

【问题讨论】:

  • 您应该能够找到足够多的教程来解释如何通过在 Google 上搜索来实现这一目标。该网站的主要重点是帮助人们编写他们编写的代码,而不是按需编写代码或解释在教程中很容易找到的东西。例如,您可以使用它来开始:jquery-howto.blogspot.de/2009/05/… 一旦您尝试过并且遇到具体代码问题,您可以在这里询问。

标签: jquery image animation transition fade


【解决方案1】:

这是一个旋转图像的小提琴示例:

img {
    display: block;
margin: 20px;
}

img {
-webkit-transition-duration: 1s;
    -moz-transition-duration: 1s;
    -o-transition-duration: 1s;
    transition-duration: 1s;
    -webkit-transition-property: -webkit-transform;
    -moz-transition-property: -moz-transform;
    -o-transition-property: -o-transform;
    transition-property: transform;
}

img:hover {
transform: rotate(45deg);
-webkit-transform: rotate(45deg);
-ms-transform: rotate(45deg);
}
<img src="http://lorempixel.com/400/200/" alt="" />

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2011-12-10
    • 1970-01-01
    • 2013-01-15
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2011-01-03
    相关资源
    最近更新 更多