//
// @(#)controlVisibility.js   1.0 10/22/2001
//

//
// This library file can be used by any JavaScript enabled web page to control
// the visibility of <DIV> or <LAYER> objects. Including this file as an 
// external file by using following code snippet will give access to this 
// library functions. 
// <script src="/location/controlVisibility.js"></script>
// 
// @version    1.0 10/22/2001
// @since      JavaScript1.1
//

//
// Toggles the objects - visible or hidden
//
function ToggleVisible(id)
{
    if(id.style.visibility == "hidden"){   id.style.visibility = "visible";    }
    else{   id.style.visibility = "hidden"; }
}

//
// Sets the object to be visible
//
function SetVisible(id)
{
	var option = 'visible';
   	if(document.all){			document.all(id).style.visibility=option;}
	else if(document.layers){		document.layers[id].visibility=option;}
	else if(document.getElementById && document.getElementById(id) && document.getElementById(id).style){ 	document.getElementById(id).style.visibility=option;} 
}

//
// Sets the object to be invisible or hidden
//
function SetInvisible(id)
{
	var option = 'hidden';
   	if(document.all){			document.all(id).style.visibility=option;}
	else if(document.layers){		document.layers[id].visibility=option;}
   	else if(document.getElementById && document.getElementById(id) && document.getElementById(id).style){	document.getElementById(id).style.visibility=option;}
}