-1
A
回答
1
如果你挖空你的搜索,你會發現很多例子。 例如,來自here我發現這一點:
$(function() {
var $elie = $(selectorForElementsToRotate);
rotate(0);
function rotate(degree) {
// For webkit browsers: e.g. Chrome
$elie.css({ WebkitTransform: 'rotate(' + degree + 'deg)'});
// For Mozilla browser: e.g. Firefox
$elie.css({ '-moz-transform': 'rotate(' + degree + 'deg)'});
// Animate rotation with a recursive call
setTimeout(function() { rotate(++degree); },5);
}
});
+1
來自另一個答案的代碼的另一個副本,在這裏:http://stackoverflow.com/a/3792085/237838 – 2013-04-22 13:51:20
相關問題
- 1. CSS2選擇器和IE
- 2. 如何使用Compass background-with-css2-fallback mixin?
- 3. 如何從html5和css2製作epub
- 4. 如何使用CSS2/js/html使div容器不可選擇
- 5. CSS3 /晚期CSS2跨瀏覽器兼容(可能與jQuery)
- 6. 像使用flexbox但在CSS2中的單元定位?
- 7. 是否可以使用css2生成漸變?
- 8. 未設置attr時使用CSS2設計樣式
- 9. CSS3翻譯方法和CSS2相對定位有什麼區別?
- 10. CSS2版本的高度:calc(100% - 18px)
- 11. 100%容器高度問題--HTML5/CSS2/3
- 12. 支持CSS2'系統顏色'有多好?
- 13. 設計Web應用時應使用哪種技術 - HTML5 + CSS3或HTML4 + CSS2?
- 14. 使用jQuery和ScrollMagic
- 15. 使用jQuery和Javascript
- 16. 使用jQuery和Ajax
- 17. 使用jQuery和PHP
- 18. 與和使用jQuery
- 19. 使用和jQuery的
- 20. 使用CSS和jQuery
- 21. 使用MSMQ和Jquery
- 22. 使用Ajax和jQuery
- 23. 使用jQuery和Jade
- 24. 使用PHP和JQuery
- 25. 使用jQuery和Ajax
- 26. 使用PHP和jQuery
- 27. 使用jquery和AJAX
- 28. 使用Cookie和jQuery
- 29. 使用$(this)和jQuery
- 30. 使用CSS和jQuery
http://stackoverflow.com/questions/382591/rotating-a-div-element-in-jquery – gaynorvader 2013-03-26 14:20:01
https://developer.mozilla.org/ en-US/docs/CSS/transform – Blazemonger 2013-03-26 14:22:52
我發現了很多可以幫助您使用jQuery旋轉的示例:[https://code.google.com/p/jqueryrotate/wiki/Examples](https://code。 google.com/p/jqueryrotate/wiki/Examples) – Djouuuuh 2013-03-26 14:24:15