Posted in Javascript onNovember 20, 2013
鼠标滚轮改变图片大小的示例代码
<script>
function onWheelZoom(obj){
zoom = parseFloat(obj.style.zoom);
tZoom = zoom + (event.wheelDelta>0 ? 0.05 : -0.05);
if( tZoom > 1 || tZoom<0.1 ) return true;
obj.style.zoom=tZoom;
return false;
}
</script>
<a href="javascript:window.close()"><img
src="//img.jbzj.com/file_images/article/201311/20131120101711.png" style="zoom:1;"
onmousewheel='return onWheelZoom(this)'></a>
鼠标滚轮改变图片大小的示例代码
声明:登载此文出于传递更多信息之目的,并不意味着赞同其观点或证实其描述。
Reply on: @reply_date@
@reply_contents@