// JavaScript Document

function HideFeatures ()
{
	var CurrentFeature;
	var Features;

	Features           = document.getElementById('contacts');
	
	var IndivFeatures = Features.getElementsByTagName('div');
	
	//loop through the child "div" tags of the MainFeatures div.
	//          This will hide all of the Features.
	for (var i = 0; i < IndivFeatures.length; i++)
	{           
		CurrentFeature = IndivFeatures[i].id; 
		//if the element isn't "" or Undefined, update the div by calling the change function...
		try
		{
			if (CurrentFeature != "" && CurrentFeature.toLowerCase() != 'undefined')
			{
				NewFeatureStyle = change(CurrentFeature, 'hide')
			}
		}
		catch(ex)
		{;}
	}
}

function HideFeatures2 ()
{
	var CurrentFeature;
	var Features;

	Features           = document.getElementById('moreMenu');
	
	var IndivFeatures = Features.getElementsByTagName('div');
	
	//loop through the child "div" tags of the MainFeatures div.
	//          This will hide all of the Features.
	for (var i = 0; i < IndivFeatures.length; i++)
	{           
		CurrentFeature = IndivFeatures[i].id; 
		//if the element isn't "" or Undefined, update the div by calling the change function...
		try
		{
			if (CurrentFeature != "" && CurrentFeature.toLowerCase() != 'undefined')
			{
				NewFeatureStyle = change(CurrentFeature, 'hide')
			}
		}
		catch(ex)
		{;}
	}
}


function change(elem, action) 
{
	if (action == 'hide')
		document.getElementById(elem).style.display = 'none';
	else if (action == 'show')
		{document.getElementById(elem).style.display = 'block';}

}


var saveXX;
function dsp(xx) {
	if (saveXX) {
		if (xx != saveXX) {
			document.getElementById(saveXX).style.display = "none";
		}
	}
	saveXX = xx;
	var xy = document.getElementById(xx).style.display;
	document.getElementById(xx).style.display = (xy != "block") ? "block" : "none";
}
