
	//********************************************************
	//
	//	findObject() function
	//
	//	DESCRIPTION
	//	this function searches a parent container (such as a form
	//	or document) for an element and returns an object reference
	//	to that element.
	//
	//	INPUTS:
	//		strObjectName : String (Required)
	//			- the name of the object being sought
	//		objDoc : Object (Optional)
	//			- the name of the parent container being searched
	//
	//	OUTPUTS:
	//		Reference to the object
	//
	//********************************************************

	function findObject(strObjectName, objDoc)
		{

			var intQuestionMarkPosition;
			var i;
			var obj;


			// if no parent container is supplied, the default will be set to document level
			if (!objDoc)
				{
					objDoc = document;
				}


			// the following IF clauses evaluate several permutations of browser/syntax
			// to return the appropriate object reference
			if ((intQuestionMarkPosition = strObjectName.indexOf("?")) > 0 && parent.frames.length)
				{
					objDoc = parent.frames[strObjectName.substring(intQuestionMarkPosition + 1)].document;
					strObjectName = strObjectName.substring(0, intQuestionMarkPosition);
				}


			if (!(obj = objDoc[strObjectName]) && objDoc.all)
				{
					obj = objDoc.all[strObjectName];
				}


			for (i=0; !obj && i < objDoc.forms.length; i++)
				{
					obj = objDoc.forms[i][strObjectName];
				}


			for (i=0; !obj && objDoc.layers && i < objDoc.layers.length; i++)
				{
					obj = findObject(strObjectName, objDoc.layers[i].document);
				}


			if (!obj && objDoc.getElementById)
				{
					obj = objDoc.getElementById(strObjectName);
				}


			return obj;

		}


	//********************************************************
	//
	//	preloadImages() function
	//
	//	DESCRIPTION
	//	this function populates the selected images of a page
	//	en masse, rather than piecemeal
	//
	//	INPUTS:
	//		Dynamic list of arguments : String (Required)
	//
	//	OUTPUTS:
	//		None
	//
	//********************************************************

	function preloadImages()
		{

			var objDoc = document;
			var i;
			var j;
			var a = preloadImages.arguments;


			if(objDoc.images)
				{

					if(!objDoc.arrPreload)
						{
							objDoc.arrPreload = new Array();
						}

					j = objDoc.arrPreload.length;

					for(i=0; i < a.length; i++)
						{
							if (a[i].indexOf("#") != 0)
								{
									objDoc.arrPreload[j] = new Image;
									objDoc.arrPreload[j++].src = a[i];
								}
						}
				}
		}


	//********************************************************
	//
	//	restoreImage() function
	//
	//	DESCRIPTION
	//	this function returns a rollover image to its original source
	//
	//	INPUTS:
	//		None
	//
	//	OUTPUTS:
	//		None
	//
	//********************************************************

	function restoreImage()
		{

			var obj;
			var a = document.arrImage;

			obj = a[0];
			obj.src = obj.oSrc;

		}


	//********************************************************
	//
	//	swapImage() function
	//
	//	DESCRIPTION
	//	this function replaces an existing image with a new image
	//
	//	INPUTS:
	//		strOldImage : String (Required)
	//			- the name of the image being replaced
	//		strNewImage : String (Required)
	//			- the name of the new image
	//
	//	OUTPUTS:
	//		None
	//
	//********************************************************

	function swapImage(strOldImage, strNewImage)
		{

			var x = 0;
			var obj;


			document.arrImage = new Array;


			if ((obj = findObject(strOldImage)) != null)
				{
					document.arrImage[x++] = obj;
					if (!obj.oSrc)
						{
						 	obj.oSrc = obj.src;
						}
					obj.src = strNewImage;
				}
		}


	//********************************************************
	//
	//	openWindow() function
	//
	//	DESCRIPTION
	//	this function opens a popup window
	//
	//	INPUTS:
	//		url : String (Required)
	//			- the page url being opened
	//		intWidth : Integer (Required)
	//			- the width of the popup window
	//		intHeight : Integer (Required)
	//			- the height of the popup window
	//
	//	OUTPUTS:
	//		None
	//
	//********************************************************

	function openWindow(url, intWidth, intHeight)
	{
		var features = 'scrollbars=no,location=no,resizable=no,status=no,toolbar=no,menubar=no,width=' + intWidth + ',height=' + intHeight + ',left=100,top=100';
		newWindow = window.open(url, "popWindow", features)
	}


	//********************************************************
	//
	//	closesWindow() function
	//
	//	DESCRIPTION
	//	this function closes a popup window
	//
	//	INPUTS:
	//		None
	//
	//	OUTPUTS:
	//		None
	//
	//********************************************************

	function closeWindow()
	{
		window.close()
	}


	//********************************************************
	//
	//	sendData() function
	//
	//	DESCRIPTION
	//	this function coordinates communication w/ the data 
	//	page via XMLHTTP and manages retrieving/updating/inserting data

	//
	//	INPUTS:
	//		objRequestDOM : Object [XML DOM] (Required)
	//			- the DOM containing the request XML to be
	//				sent to the data page
	//		strPostPage : String (Required)
	//			- the name of the page that will process the DOM
	//
	//	OUTPUTS:
	//		XML DOM
	//
	//********************************************************

	function sendData(objRequestDOM, strPostPage)
		{

			var xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");

			xmlhttp.Open("POST", strPostPage, false);
			xmlhttp.Send(objRequestDOM.xml);

			return xmlhttp.responseXML;

		}

var popTimer = 0;
var popTimerSub = 0;
var popTimer2 = 0;
var passthru = "";
var passthruParent = "";

function popOver(target, mainNavItem, leftPos, blnSub) 
{

	if(passthru != "" && passthruParent != "" && passthru != target && blnSub != 1)
	{
//alert(blnSub);
		hidemenu(passthru, passthruParent);
	}


	if (window.innerWidth || window.innerHeight)
	{ 
		docwidth = window.innerWidth;
		docheight = window.innerHeight;
	} 
	//IE Mozilla 
	if (document.body.clientWidth || document.body.clientHeight)
	{ 
		docwidth = document.body.clientWidth;
		docheight = document.body.clientHeight;
	} 
	//if docwidth is less than our table then position the menu 189px from left
	if(docwidth <= 760) 
	{
		document.getElementById(target).style.left = leftPos;
	}
	else
	{
		//subtract the width of the table and divide by 2 to get left margin
		totalMargin = docwidth - 760;
		leftMargin = parseInt(totalMargin / 2);
		document.getElementById(target).style.left = leftMargin + leftPos;
	}
	document.getElementById(target).style.top = 70;
/*
	if(docheight <= 484) 
	{
		document.getElementById(target).style.top = 70;
	}
	else
	{
		//subtract the width of the table and divide by 2 to get left margin
		totalMargin = docheight - 484;
		topMargin = parseInt(totalMargin / 2);
		document.getElementById(target).style.top = topMargin + 70;
	}
*/

	clearTimeout(popTimer);
	document.getElementById(target).style.visibility = 'visible';
}

function hidemenu(target)
{
    document.getElementById(target).style.visibility = 'hidden';
}

function hidesubmenus()
{
    document.getElementById('nav1menu_sub1').style.visibility = 'hidden';
}
function hidetopmenus()
{
    document.getElementById('nav1menu').style.visibility = 'hidden';
    document.getElementById('nav2menu').style.visibility = 'hidden';
}

function popOut(target, timerType) 
{
	passthru = target;
	if(timerType == 1)
	{
	    popTimer = setTimeout("hidemenu(passthru)", 600);
	}
	else
	{
	    popTimer2 = setTimeout("hidemenu(passthru)", 600);	
	}
}

function popOut2() 
{
	popTimerSub  = setTimeout("hidesubmenus()", 600);
}
//-----------------------------------------------------------------
// Method jsTreeNode.collapse()
//-----------------------------------------------------------------
// Author(s)
//  Nicholas C. Zakas (NCZ), 1/27/02
//
// Description
//  This method expands the jsTreeNode's children to be hidden.
//
// Parameters
//  (none)
//
// Returns
//  (nothing)
//-----------------------------------------------------------------
function toggleExpand(div)
 {

    //check to see if the node is already collapsed (NCZ, 1/27/02)
    if (document.getElementById(div).style.display == "none")
	{
    
        //throw an error (NCZ, 1/27/02)
        document.getElementById(div).style.display = "block";

    }
	 else
	{
    
        //hide the child nodes (NCZ, 1/27/02)
        document.getElementById(div).style.display = "none";
    }
}


