强大的基于jQuery的图片切割插件,图片选择框可以按一定的比例实现。 实例代码: [code] <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "//www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="//www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=gb2312" /> <title>imgAreaSelect jQuery plugin - Examples</title> <script src="//ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></script> <script src="scripts/jquery.imgareaselect.pack.js"></script> <link rel="stylesheet" type="text/css" href="css/imgareaselect-default.css" /> </head> <body> <div> <script type="text/javascript"> $(function () { $('#ladybug_ant').imgAreaSelect({ maxWidth: 200, maxHeight: 150, handles: true }); $('#bee').imgAreaSelect({ aspectRatio: '4:3', handles: true }); $('#duck').imgAreaSelect({ x1: 120, y1: 90, x2: 280, y2: 210 }); }); </script> </div> <p style="text-align: center;"> <img id="ladybug_ant" src="ladybug_ant.jpg" alt="A ladybug being harassed by an ant." title="A ladybug being harassed by an ant."> </p> <p style="text-align: center;"> <img id="bee" src="bee.jpg" alt="Busy bee" title="Busy bee"> </p> <p style="text-align: center;"> <img id="duck" src="duck.jpg" alt="Why did the duck cross the road?" title="Why did the duck cross the road?"> </p> </body> </html> [/code]
立即下载
下载方法:
1、请用微信扫描下方二维码关注
时代Java 公众号,或者微信搜索
时代Java 或
NowJava 关注。
(如已经关注,请直接发送编号)
2、在
时代Java 公众号里发送编号:
5902
5902
3、发送后,将立刻收到 “验证码已经接收成功” 的回复,即可选择线路下载:
通用网络下载 移动网络下载 电信网络下载
如不能正常下载请联系我们:nowjava@qq.com 或 公众号里留言。
本文系作者在时代Java发表,未经许可,不得转载。
如有侵权,请联系nowjava@qq.com删除。
编辑于 2020-02-20 18:08:582020-02-20 18:08:58