我的代码中有这个元素:
<img id="pswheel" src="images/wheel.png" style="transform: rotate(315deg); transform-origin: 50% 50% 0px;">
现在我想在单击事件中将旋转值从 315 更改为 0。我该怎么做?
最佳答案
试试这个:
$('elementtoclick').click(function(){
$('img').css('transform','rotate(0deg)');
})
关于jquery - 使用 jQuery 更改 CSS 旋转值,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21100518/