// ZOOM FUNCTION BEGIN

var zoomfactor=0.02 //Enter factor (0.05=5%)

function zoomhelper()
{if(parseInt(whatcache.style.width)>10&&parseInt(whatcache.style.height)>10)
   {whatcache.style.width=parseInt(whatcache.style.width)+parseInt(whatcache.style.width)*zoomfactor*prefix
    whatcache.style.height=parseInt(whatcache.style.height)+parseInt(whatcache.style.height)*zoomfactor*prefix
   }
}

function zoom(originalW, originalH, what, state)
             {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()",100)
}

function clearzoom(){
if (window.beginzoom)
clearInterval(beginzoom)
}

// ZOOM FUNCTION END

// DETAILS VIEW BEGIN
var tvar=0;
   function MachText(feld_text)
       {
         if (tvar==0)
          {
            document.getElementById('text_feld').innerHTML=feld_text;
            tvar=0;
          }
         else if (tvar==1)
          {
            document.getElementById('text_feld').innerHTML=feld_text;
            tvar=2;
          }
       }
// DETAILS END 
	   

// CLIP FUNCTION OF PRODUCT DETAILS BEGIN

	function PictureChange(PicName,PicNumber,PicWidth,PicHeight)
{
	document.PictureDetail.src		= PicNumber;
	document.PictureDetail.width	= PicWidth;
	document.PictureDetail.height	= PicHeight;
}

var nextPic = 0;
function PictureChangeNext(PicName)
{
	if(document.DetailBlock.anz_picture.value > 0)
	{	
		this.nextPic++;
		if(document.DetailBlock.pictureUrl[this.nextPic] == null)
			this.nextPic = 0;
			
		if(document.DetailBlock.anz_picture.value <= 1)
		{
			document.PictureDetail.src		= document.DetailBlock.pictureUrl.value;
			document.PictureDetail.width	= document.DetailBlock.pictureWidth.value;
			document.PictureDetail.height	= document.DetailBlock.pictureHeight.value;
		} else {
			document.PictureDetail.src		= document.DetailBlock.pictureUrl[this.nextPic].value;
			document.PictureDetail.width	= document.DetailBlock.pictureWidth[this.nextPic].value;
			document.PictureDetail.height	= document.DetailBlock.pictureHeight[this.nextPic].value;
		}	
	}
}
// CLIP FUNCTION OF PRODUCT DETAILS END

