function fzandloper(bVisible)
{
	//var ns4 = (document.layers)? true:false
	var IE = (document.all)? true:false
	
	if (IE)
	{
		zandloper.style.top=document.body.scrollTop+5
		if(bVisible==true)
			zandloper.style.visibility="visible"
		else
			zandloper.style.visibility="hidden"
	}
	else
	{
		if(bVisible==true)
			document.zandloper.style.visibility="show"
		else
			document.zandloper.style.visibility="hide"
	}
}

function enlarge(which,e)
{
	//Render image code for IE 4+
	if (document.all)
	{
		if (showimage.style.visibility=="hidden")
		{
			fzandloper(true);
			showimage.style.left=document.body.scrollLeft+175
			showimage.style.top=document.body.scrollTop+80
			showimage.innerHTML='<img onload="fzandloper(false);" onmouseup="return imagemove()" style="cursor: move;" src="'+which+'">'
			showimage.style.visibility="visible"
			showimage.LastLeft = showimage.style.left
			showimage.LastTop = showimage.style.top
		}
		else
			showimage.style.visibility="hidden"
		return false
	}
	//Render image code for NS 4
	else if (document.layers)
	{
		if (document.showimage.visibility=="hide")
		{
			document.showimage.document.write('<a href="#" onMouseover="drag_dropns(showimage)">&nbsp;<img src="'+which+'" border=0></a>')
			document.showimage.left=e.x
			document.showimage.top=e.y
			document.showimage.visibility="show"
			document.showimage.LastLeft = document.showimage.left
			document.showimage.LastTop = document.showimage.top		
		}
		else
			document.showimage.visibility="hide"
		return false
	}
	//if NOT IE 4+ or NS 4, simply display image in full browser window
	else
		return true
}

function imagemove()
{
	//Image code for IE 4+
	if (document.all){
		if (event.button != 1) return false
		if (showimage.LastLeft == showimage.style.left && showimage.LastTop == showimage.style.top)
			showimage.style.visibility="hidden"
		else {
			showimage.LastLeft = showimage.style.left
			showimage.LastTop = showimage.style.top
		}
		return false
	}
	else
		return true
}

//By Dynamicdrive.com

//drag drop function for NS 4////
/////////////////////////////////

var nsx
var nsy
var nstemp

function drag_dropns(name)
{
	temp=eval(name)
	temp.captureEvents(Event.MOUSEDOWN | Event.MOUSEUP)
	temp.onmousedown=gons
	temp.onmousemove=dragns
	temp.onmouseup=stopns
}

function gons(e)
{
	temp.captureEvents(Event.MOUSEMOVE)
	nsx=e.x
	nsy=e.y
}

function dragns(e)
{
	temp.moveBy(e.x-nsx,e.y-nsy)
	return false
}

function stopns()
{
	temp.releaseEvents(Event.MOUSEMOVE)
}

//drag drop function for IE 4+////
/////////////////////////////////

var dragapproved=false

function drag_dropie()
{
	if (dragapproved==true)
	{
		document.all.showimage.style.pixelLeft=tempx+event.clientX-iex
		document.all.showimage.style.pixelTop=tempy+event.clientY-iey
		return false
	}
}

function initializedragie()
{
	if (event.srcElement.parentElement.id=="showimage")
	{
		iex=event.clientX
		iey=event.clientY
		tempx=showimage.style.pixelLeft
		tempy=showimage.style.pixelTop
		dragapproved=true
		document.onmousemove=drag_dropie
	}
}

if (document.all)
{
	document.onmousedown=initializedragie
	document.onmouseup=new Function("dragapproved=false")
}
