我在这里使用这个jQuery Rotate Plugin:
http://code.google.com/p/jqueryrotate/
该插件应该在IE7,IE8,IE9等中完美地旋转图像。我可以毫无问题地旋转图像:
http://jsfiddle.net/zmpdS/101/
但是,我面临的问题是链接两个函数.rotate()
(由插件提供)和.animate()
(在jQuery核心中提供)
问题是上面列出的jQuery Rotate
插件使用RVML
在IE8和IE7中旋转图像,而在其他浏览器中它是CSS3旋转。因此,对于RVML
,DOM被操纵,新的RVML
标签不支持.animate()
功能。
有出路吗?
$(window).load(function() {
$("#test").rotate({
angle: 0,
animateTo: -90,
duration: 2000,
easing: $.easing.EaseOutQuint
}).animate({
height: "128px",
width: "128px"
}, 1000);
});
看一下这个
http://jsfiddle.net/zmpdS/103/
$(window).load(function() {
$("#test").rotate({
angle: 0,
animateTo:180,
callback: function(){
$("#test").animate({
height: "128px",
width: "128px"
}, 1000);
}
})
});