Dailycoding.com

Download source | Back to article


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

Demo 1 - Default lens

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

 

Demo 2 - Custom lens size

$("#img_02").imageLens({ lensSize: 200 });

 

Demo 3 - Custom image source

$("#img_03").imageLens({ imageSrc: "sample01.jpg" });

 

Demo 4 - Other lens properties

$("#img_04").imageLens({ borderSize: 8, borderColor: "#06f" });
 

Image courtesy http://www.smashingmagazine.com/