//Image zoom in/out script- by javascriptkit.com
//Visit JavaScript Kit (http://www.javascriptkit.com) for script
//Credit must stay intact for use

var zoomfactor=0.1 //Enter factor (0.05=5%)
var n_zoom = 0;
var i_zoom = 0;

function zoomhelper(){
if (n_zoom > 0)
{
	if (i_zoom > n_zoom) return;
	i_zoom++;
}
if (parseInt(whatcache.style.width)>10&&parseInt(whatcache.style.height)>10){
whatcache.style.width=(parseInt(whatcache.style.width)+parseInt(whatcache.style.width)*zoomfactor*prefix)+"px"
whatcache.style.height=(parseInt(whatcache.style.height)+parseInt(whatcache.style.height)*zoomfactor*prefix) + "px"
}
}

function zoom(originalW, originalH, what, state, _n_zoom){
i_zoom = 1;
n_zoom = _n_zoom
clearzoom()
if (!document.all&&!document.getElementById)
return
whatcache=eval("document.images."+what)
prefix=(state=="in")? 1 : -1
if (whatcache.style.width==""||state=="restore"){
	
whatcache.style.width=originalW+"px"
whatcache.style.height=originalH+"px"
if (state=="restore")
return
}
else{
zoomhelper()
}

beginzoom=setInterval("zoomhelper()",10)
}

function clearzoom(){
if (window.beginzoom)
clearInterval(beginzoom)
}
