jquery.imageLens 图片放大镜效果

I was searching a good jQuery plug-in for image zooming but couldn't find any which was matching my criteria. I need the lens effect while zooming images and it should work without much plumbing. So, I decided to create one and now sharing this with everyone.

What I need to use this?

  1. jQuery

  2. ImageLens plug-in – jquery.imagelens.js

  3. An image

如何使用?

Include jQuery and jquery.imageLens.js in you web page -

<script src="jquery.js" type="text/javascript"></script>
<script src="jquery.imageLens.js" type="text/javascript"></script>

For default image lens just use imageLens as below. Note that it will automatically calculate actual size of image and start showing zooming -

$("#img_01").imageLens();

Note - If you are using IE 8 or lower than you will see a square lens


   源码及下载


赞(52) 打赏
未经允许不得转载:优客志 » 前端设计
分享到:

觉得文章有用就打赏一下文章作者

支付宝扫一扫打赏

微信扫一扫打赏