Log in

View Full Version : increase the size of zoom window



letom
07-10-2012, 07:23 AM
Hi

please refer the site http://harvestcfood.com/frm/
1. click the thumbnail
2. hover the big image.

Can any body help how to increase the size of zoom window appearing while hover the image.

Regards

vwphillips
07-10-2012, 10:50 AM
try

http://www.vicsjavascripts.org.uk/ImageViewerIII/ImageViewerIII.htm

this can be modified to use the natural image size on image swap

the modified function(mods in red)


load:function(o){
for (var oop=this,z0=0;z0<o.nimg.length;z0++){
if (o.nimg[z0].width<40){
o.dly=setTimeout(function(){ oop.load(o); },100);
return;
}
}
if (!o.init){
o.iw=o.img.width;
o.ih=o.img.height;
this.resize(null,o);
o.v.appendChild(o.vimg);
this.vpos(null,o);
this.addevt(o.img,'mouseover','vpos',o);
this.addevt(o.img,'mousemove','move',o);
this.addevt(o.msk,'mousemove','move',o);
this.addevt(o.msk,'mouseover','move',o);
this.addevt(o.img,'mouseout','out',o);
this.addevt(o.msk,'mouseout','out',o);
o.init=true;
}
else {
o.iw=o.nimg[0].width;
o.ih=o.nimg[0].height;
o.img.style.width=o.iw+'px';
o.img.style.height=o.ih+'px';
o.img.src=o.nimg[0].src;
o.vimg.src=o.nimg[1].src;
}
},

letom
07-11-2012, 06:11 AM
Hi @vwphillips

It's got working .. its very highly appreciated to get such a valuable advice from you..
Noted your message :)
This code is very friendly with php programming

Regards
Tom