function displayDiv(id, condition)
{
	if(condition)
	{
		document.getElementById(id).style.display = 'block';
	}
	else
	{
		document.getElementById(id).style.display = 'none';
	}
	
}

function addClass(id, theClassName)
{
	document.getElementById(id).className += " " + theClassName;
}

function removeClass(id, theClassName)
{
	document.getElementById(id).className = document.getElementById(id).className.replace(new RegExp(theClassName + "\\b"), "");
}

function recourceTabs(currentTab)
{
	var tabs =	[ 
					'resource_links', 
					'educational_links', 
					'glossary' 
				];
	for(var i = 0; i < tabs.length; i++)
	{
		try
		{
			displayDiv(tabs[i], 0);
			removeClass(tabs[i] + "_tab", 'tabOn');
		}catch(e){}
		
	}
	try
	{
		displayDiv(currentTab, 1);
		addClass(currentTab + "_tab", 'tabOn');
	}catch(e){}
	
	return false;
}