摘要:
01//图片加载完成后按最大宽高等比缩放02function resize(o,mw,mh){03 var ow=o.width,oh=o.height,os=ow/oh,w=mw||100,h=mh||100,s=w/h;04 o.setAttribute('oldheight',oh)05 if(os>s){06 if(ow>w){07 o.width=w;o.height=w/os;08 }09 }else{10 if(oh>h){11 o.height=h;o.width=h*... 阅读全文
posted @ 2013-05-10 09:55
求必印
阅读(286)
评论(0)
推荐(0)

浙公网安备 33010602011771号