// 4/3/04 john bennett added ShowMenu function for world popupmenu

function showMenu(objID,yVal,tableCellRef, hoverFlag, navStyle) {


if ( hoverFlag ) {
switch ( navStyle ) {
case 1:
tableCellRef.style.backgroundColor = '#52567B';//69c
tableCellRef.getElementsByTagName( 'a' )[0].style.color = '#FFFFFF'; //c00
break;
default:
if ( document.getElementsByTagName ) {
tableCellRef.getElementsByTagName( 'a' )[0].style.color = '#FFFFFF'; //c00
}
}
} else {
switch ( navStyle ) {
case 1:
tableCellRef.style.backgroundColor = '#D6D6D6';
tableCellRef.getElementsByTagName( 'a' )[0].style.color = '#000000';
break;
default:
if ( document.getElementsByTagName ) {
tableCellRef.getElementsByTagName( 'a' )[0].style.color = '#000000';
}}}

//This function receives the object ID and y-coordinate value (in pixels)
//from the event handler and then uses those values to dynamically
//position the object in the browser window

if (document.all) {

//This checks to see if the user is using Internet Explorer
//because only IE uses "document.all"

objName = eval('document.all.' + objID + '.style');

//This statement creates the object reference for IE from
//object ID sent to the script

objName.pixelTop = yVal;

//This sets the y-coordinates of the top of the object
//for users browsing with Internet Explorer

} else {

//If user is not using Internet Explorer do what follows

objName = eval('document.getElementById("' + objID + '")');

//Create the object reference for Netscape using
//the object ID sent to the script

objName.style.top = yVal;

//Set the y-coordinate for the top of the object
//for users browsing with Netscape
}




}

function navBarHover( tableCellRef, hoverFlag, navStyle ) {
if ( hoverFlag ) {
switch ( navStyle ) {
case 1:
tableCellRef.style.backgroundColor = '#52567B';//69c
tableCellRef.getElementsByTagName( 'a' )[0].style.color = '#FFFFFF'; //c00
break;
default:
if ( document.getElementsByTagName ) {
tableCellRef.getElementsByTagName( 'a' )[0].style.color = '#FFFFFF'; //c00
}
}
} else {
switch ( navStyle ) {
case 1:
tableCellRef.style.backgroundColor = '#D6D6D6';
tableCellRef.getElementsByTagName( 'a' )[0].style.color = '#000000';
break;
default:
if ( document.getElementsByTagName ) {
tableCellRef.getElementsByTagName( 'a' )[0].style.color = '#000000';
}}}}

/*
		function navBarHover( tableCellRef, hoverFlag, navStyle ) {
			if ( hoverFlag ) {
				switch ( navStyle ) {
					case 1:
						tableCellRef.style.backgroundColor = '#52567B';//button on color
//							tableCellRef.getElementsByTagName('a')[0].style.color = '#FFFFFF';
						break;
					default:
						if ( document.getElementsByTagName ) {
							tableCellRef.getElementsByTagName('a')[0].style.color = '#FFFFFF';
						}
				}
			} 
			else {
				switch ( navStyle ) {
					case 1:
						tableCellRef.style.backgroundColor = '#D6D6D6';//button off color
	//					tableCellRef.getElementsByTagName('a')[0].style.color = '#000000';
						break;
					default:
						if ( document.getElementsByTagName ) {
							tableCellRef.getElementsByTagName('a')[0].style.color = '#000000';
						}
				}
			}
		}*/
/*
		function navBarHover( tableCellRef, hoverFlag, navStyle ) {
if ( hoverFlag ) {
switch ( navStyle ) {
case 1:
tableCellRef.style.backgroundColor = '#69c';
break;
default:
if ( document.getElementsByTagName ) {
tableCellRef.getElementsByTagName( 'a' )[0].style.color = '#c00';
}
}
} else {
switch ( navStyle ) {
case 1:
tableCellRef.style.backgroundColor = '#036';
break;
default:
if ( document.getElementsByTagName ) {
tableCellRef.getElementsByTagName( 'a' )[0].style.color = '#000';
}
}
}
}
*/
/*-------------------------------------------------------------------------------------*/		
		function navBarRightHover( tableCellRef, hoverFlag, navStyle ) {
			if ( hoverFlag ) {
				switch ( navStyle ) {
					case 1:
						tableCellRef.style.backgroundColor = '#D6D6D6';//button on color
							tableCellRef.getElementsByTagName('a')[0].style.color = '#000000';
		//				tableCellRef.style = 'LeftNavButtonOn';
						break;
					default:
						if ( document.getElementsByTagName ) {
							tableCellRef.getElementsByTagName( 'a' )[0].style.color = '#000000';
						}
				}
			} 
			else {
				switch ( navStyle ) {
					case 1:
						tableCellRef.style.backgroundColor = '#52567B';//button off color
						tableCellRef.getElementsByTagName('a')[0].style.color = '#FFFFFF';
						break;
					default:
						if ( document.getElementsByTagName ) {
							tableCellRef.getElementsByTagName( 'a' )[0].style.color = '#FFFFFF';
						}
				}
			}
		}
		
/*-------------------------------------------------------------------------------------*/		
		function IA_goTo( url ) {
			window.location.href = url;
		}
		
/*-------------------------------------------------------------------------------------*/		
		function navClick( tableCellRef, navStyle, url ) {
			navBarHover( tableCellRef, 0, navStyle );
			document.location.href = url;
		}

/*-------------------------------------------------------------------------------------*/		
		function ConfirmNewStatusAndSubmit(SID, SAction) {
			question = 'Are you sure you want to ' + SAction + '?';
			if (confirm(question)) {
				document.statusForm.newstatus.value = SID;
				return true;
				}
			else
				return false;
			}

/*-------------------------------------------------------------------------------------*/		
