Welcome Here And Thanks For Visiting. Like Us On Facebook...

EXEIdeas – Let's Your Mind Rock » HTML-CSS-PHP-JavaScript / JavaScript Codes » jQuery Image Zoom On Hover Plugin For Blogger And Website

jQuery Image Zoom On Hover Plugin For Blogger And Website

jQuery Image Zoom On Hover Plugin For Blogger

Here we are with a WordPress Plugin that after some customization, working for blogger too. This codes is known as “Easy Zoom” By “CSSGlobe“. In blogger, you have to do some tweaks to use but after one time editing, it will be soo easy as in WordPress. There are many script available for the same purpose but some of them are heavy actually. So here we have best and quick loading script that we are gonna share with you.

In many scripts, they have the same image for thumbnail and zoom. They just change the thumbnail width and height that can cause bad image result or if you will upload a HD image in thumbnail then your load time will be hight. So here in this code, It work on basis of two images. Like one is small(thumbnail) and other is big(after zoom). When you have your mouse over small image then it will automatically show a DIV beside the small image and in which it has big image and it just keep scrolling to that where you move your mouse pointer in small image. So through this process, your load time will not gonna high because it will load your zoom image on mouse hove only with a loading text and will not show little little image while loading, it will load image behind and till then, it keep showing loading text and after some time, it will show whole image in zoom.

You have to add this code in your blogger template once only. The only thing you have to do more is to add class to your desired zoom-able image as class = “zoom” and nothing more. After it, it will be like <a class=”zoom” href=”large.jpg”><img src=”small.jpg”></a> So Now with any more preface, here first see the live DEMO then check out features list and garb the code and enjoy.


1.) Pure JavaScript/JQuery Code.
2.) Easy Zoom 1.0 By Alen Grakalic.
3.) Different Images As Small And Zoom.
4.) Cross Browsers Completable.
5.) Work With All Version Of JQuery File.
6.) Stylish Zooming Effect.
7.) Awesome Smoothness.
8.) Little JavaScript Code.
9.) No External File Added.
10.) Work On Unlimited Images.
11.) Easy To Add In Blogger.
12.) Quick To Load With Loading Text And Error.

How To Add In Blogspot?

1.) Go To Your
2.) Open Your Desire “Blog“.
3.) Go To “Template“.
4.) Click “Edit HTML“.
5.) Now Click Within Code Box.
6.) Press [CTRL+F] To Search </head> Code.
7.) Now Copy The Below Code And Paste It Before Code..
8.) Click “Save Template” And Done.

<script src="" type="text/javascript"></script>
<script type="text/javascript">
* Easy Zoom 1.0 - jQuery plugin
* written by Alen Grakalic
* Copyright (c) 2011 Alen Grakalic (
* Dual licensed under the MIT (MIT-LICENSE.txt)
* and GPL (GPL-LICENSE.txt) licenses.
* Built for jQuery library
Required markup sample
<a href="large.jpg"><img src="small.jpg" alt=""></a>
(function($) {
$.fn.easyZoom = function(options){
var defaults = {
id: 'easy_zoom',
parent: 'body',
append: true,
preload: 'Loading...',
error: 'There has been a problem with loading the image.'
var obj;
var img = new Image();
var loaded = false;
var found = true;
var timeout;
var w1,w2,h1,h2,rw,rh;
var over = false;
var options = $.extend(defaults, options);
obj = this;
// works only for anchors
var tagName = this.tagName.toLowerCase();
if(tagName == 'a'){
var href = $(this).attr('href');
img.src = href + '?' + (new Date()).getTime() + ' =' + (new Date()).getTime();
$(img).error(function(){ found = false; })
img.onload = function(){
loaded = true;
.click(function(e){ e.preventDefault(); })
.mouseover(function(e){ start(e); })
.mouseout(function(){ hide(); })
.mousemove(function(e){ move(e); })
function start(e){
var zoom = $('<div id="'+ +'">'+ options.preload +'</div>');
if(options.append) { zoom.appendTo(options.parent) } else { zoom.prependTo(options.parent) };
} else {
} else {
function loop(e){
} else {
timeout = setTimeout(function(){loop(e)},200);
function show(e){
over = true;
w1 = $('img', obj).width();
h1 = $('img', obj).height();
w2 = $('#'+;
h2 = $('#'+;
w3 = $(img).width();
h3 = $(img).height();
w4 = $(img).width() - w2;
h4 = $(img).height() - h2;
rw = w4/w1;
rh = h4/h1;
function hide(){
over = false;
function error(){
function move(e){
// target image movement
var p = $('img',obj).offset();
var pl = e.pageX - p.left;
var pt = e.pageY -;
var xl = pl*rw;
var xt = pt*rh;
xl = (xl>w4) ? w4 : xl;
xt = (xt>h4) ? h4 : xt;
$('#'+ + ' img').css({'left':xl*(-1),'top':xt*(-1)});
<script type="text/javascript">
</script type="text/css">
#easy_zoom{overflow:hidden;position:fixed;top:80px;left:220px;width:600px;height:400px;line-height:400px;text-align:center;color:#333;border:5px solid #eee;background:#fff;-moz-box-shadow:0 0 10px #555;-webkit-box-shadow:0 0 10px #555;-ms-box-shadow:0 0 10px #555;-0-box-shadow:0 0 10px #555;box-shadow:0 0 10px #555;}

9.) Now Go Where You Want Image Zoom.
10.) Add The Below Code And Save It.

<a class="zoom" href=""><img alt="Samsung-Galaxy-S-IV" src="" height="400" title="Samsung-Galaxy-S-IV" width="200" /></a>


1.) Change Blue Link With Small Image URL.
2.) Change Red Link With Small Image URL.
3.) Save And Done.

Last Words:

This is what we got. If you liked it then share it and leave your feedback. If you have any problem then you can contact so so we can solve your problem.

You Like It, Please Share This Recipe With Your Friends Using...

4 Responses to “jQuery Image Zoom On Hover Plugin For Blogger And Website”

  1. That’s a great piece of information..It’s very helpful…thank you…!!.. 🙂

  2. iliyas shaikh says:


Leave a Reply

Your email address will not be published. Required fields are marked *