<!--
function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
function popContact(){
	var x=window.open('/forms/contact.html','contact','status=no,scrollbars=yes,resizable=yes,width=470,height=470');
	//x.focus();
}
function popQualForm(){
	var x=window.open('/forms/qualform.html','contact','status=no,scrollbars=no,resizable=no,width=590,height=350');
	//x.focus();
}
function popFeedback(){
	var x=window.open('/forms/feedback.html','contact','status=no,scrollbars=no,resizable=no,width=590,height=350');
	//x.focus();
}

function zPopWindow(zURL,zName,xSize,ySize,zOptLevel) {
	// a zOptLevel value of 1 yields a window with no ornamentation, bars, menus etc
	// a zOptLevel value of 2 yields the same window as 1, but with scroll bars
	// a zOptLevel value of 3 (or nothing, or anything but 1 or 2) yields a window with full menus, etc
	W = screen.width;
	H = screen.height;
	if (!xSize) { xSize = W / 1.25; }
	if (!ySize) { ySize = H / 1.25; }
	if (!zName) { zName = "NewWindow"; }
	xPos = (W - xSize) / 2;
	yPos = (H - ySize) / 2;

	if (zOptLevel == 1) {
		var zWinOpts = 'height=' + ySize + ',width=' + xSize + ',left=' + xPos + ',top=' + yPos + 'screenX=' + xPos + ',screenY=' + yPos;
	} else if  (zOptLevel == 2) {
		var zWinOpts = 'height=' + ySize + ',width=' + xSize + ',scrollbars=yes,left=' + xPos + ',top=' + yPos + 'screenX=' + xPos + ',screenY=' + yPos;
    } else {
		var zWinOpts = 'height=' + ySize + ',width=' + xSize + ',resizable=yes,toolbar=yes,location=yes,directories=yes,status=yes,menubar=yes,scrollbars=yes,left=' + xPos + ',top=' + yPos + 'screenX=' + xPos + ',screenY=' + yPos;
	}

	var PopWin = window.open(zURL,zName,zWinOpts);
	
	
}
//-->


function OpenImage(strImageName,iWidth,iHeight) 
{
	iHeight=iHeight + 40
	var strWindowName = new String(Math.round(Math.random() * 100000));
	var iLeftPos=screen.width/2 - (iWidth/2);
	var iTopPos=screen.height/2 - (iHeight/2);
	var strFileName = "/image.html?ImageID=" + strImageName

	window.open(strFileName,strWindowName,"toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=0,width="+iWidth+",height="+iHeight+",left=" + iLeftPos + ",top=" + iTopPos );
}

function OpenNewWindow(strFileName,strWindowName,strProperties) 
{
	if (strWindowName == "NewWindow") 
	{
		//generate random window ID
		 strWindowName = new String(Math.round(Math.random() * 100000));
	}
	window.open(strFileName,strWindowName,strProperties)
}
//used for the downloadable files
function OpenDocument(strFileName) 
{
	var iWidth=680;
	var iHeight=590;
	var iLeftPos=screen.width/2 - (iWidth/2);
	var iTopPos=screen.height/2 - (iHeight/2);
	var strWindowName='View' + new String(Math.round(Math.random() * 100000));

	window.open(strFileName,strWindowName,"toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=1,width="+iWidth+",height="+iHeight+",left="+iLeftPos+",top=" + iTopPos);
}

function OpenDemo(strFileName,strWindowName) 
{
	var iWidth=644;
	var iHeight=506;
	var iLeftPos=screen.width/2 - (iWidth/2);
	var iTopPos=screen.height/2 - (iHeight/2);

	window.open(strFileName,strWindowName,"toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizable=0,width="+iWidth+",height="+iHeight+",left="+iLeftPos+",top=" + iTopPos);
}