/* Copyright © 2006, CTT Group Ltd. All Rights Reserved.
   Written by John Millard, Technical Website Developer. */
var gOM=[15,15];
var displayduration=0;
var curHeight=420;
var imgWidth=0;
var imgHeight=0;
if(document.getElementById||document.all){document.write('<div id="xImgHldr" style="position:absolute;z-Index:300;"></div>');}
function fTO(){
	if(document.getElementById){return document.getElementById("xImgHldr").style}
	else if(document.all){return document.all.xImgHldr.style}
}
function fTOnsty(){
	if(document.getElementById){return document.getElementById("xImgHldr");}
	else if(document.all){return document.all.xImgHldr;}
}
function truebody(){return (!window.opera && document.compatMode && document.compatMode!="BackCompat")?document.documentElement:document.body;}
function showGP(imagename,title,description,height){
	if(height>0){curHeight=height;}
	img=new Image();img.src=imagename;if(img.width>0){curHeight=img.width;};imgWidth=img.width;imgHeight=img.height*0.4;
if(imgWidth==640){curHeight=420;}
	document.onmousemove=fFM;
	nH='<div style="padding:5px;background-color:#FFFFFF;border:1px solid #888;"><h2>'+title+'</h2><!--<br/>'+description+'<br/>-->' + 
		'<div align="center" style="padding: 8px 2px 2px 2px;"><img src="'+imagename+'" '+(imgWidth>400?'width="400"':'height="400"')+' border="0"></div>' + 
		'</div>';
	fTOnsty().innerHTML=nH;
	fTO().visibility="visible";
}
function hideGP(){fTO().visibility="hidden";document.onmousemove="";fTO().left="-3000px";}
function fFM(e){
	var xC=gOM[0];
	var yC=gOM[1];
	var docwidth=document.all?truebody().scrollLeft+truebody().clientWidth:pageXOffset+window.innerWidth-15;
	var docheight=document.all?Math.min(truebody().scrollHeight,truebody().clientHeight):Math.min(window.innerHeight);
	if(typeof e != "undefined"){
		if(docwidth-e.pageX<curHeight){xC=e.pageX-xC-curHeight;}else{xC+=e.pageX;}
		if(docheight-e.pageY<(curHeight+imgHeight)){yC+=e.pageY-Math.max(0,(imgHeight+curHeight+e.pageY-docheight-truebody().scrollTop));}else{yC+=e.pageY;}
	}else if(typeof window.event != "undefined"){
		if(docwidth-event.clientX<curHeight){xC=event.clientX+truebody().scrollLeft-xC-(curHeight+20);}else{xC+=truebody().scrollLeft+event.clientX;}
		if(docheight-event.clientY<(curHeight+imgHeight)){
			yC+=event.clientY+truebody().scrollTop-Math.max(0,(imgHeight+curHeight+event.clientY-docheight));
		}else{yC+=truebody().scrollTop+event.clientY;}
	}
	var docwidth=document.all?truebody().scrollLeft+truebody().clientWidth:pageXOffset+window.innerWidth-15;
	var docheight=document.all?Math.max(truebody().scrollHeight,truebody().clientHeight):Math.max(document.body.offsetHeight,window.innerHeight)
	if(yC<0){yC=yC*-1;}
	fTO().left=xC+"px";
	fTO().top=yC+"px";
}