// JavaScript Document
/*
    Useful JavaScript functions that can be used to manipulate tags with ID attributes.

    Author: Scott Jibben (scott@jibben.com)
    Create: 9/27/2007 7:42 AM
    Update: 2/26/2008 3:14 PM 

	2/26/2008 3:14 PM:
	- This file replaces jcsDivUtils.js and has been renamed to make more sense.

    NOTE: THIS NEEDS TO BE INCLUDED BETWEEN THE HEAD TAGS TO BE COMPATIBLE!

    example:
    <script language="JavaScript" src="jcsIDUtils.js" type="text/javascript"></script>
	
	You could use a div tag like this for the hide/show div functions:
	<div id='myID' align="center" style="display:none; color:#FF0000">text</div>

*/

function toggleHideShowID(id) {
	var e = document.getElementById(id);
	if (e) {
		e.style.display = (e.style.display == 'none') ? 'block' : 'none';
	}
/*
	if(e.style.display == 'none')
		e.style.display = 'block';
	else
		e.style.display = 'none';
*/
}

function hideID(id) {
	var e = document.getElementById(id);
	if (e) {
		e.style.display = 'none';
	}
}

function showID(id) {
	var e = document.getElementById(id);
	if (e) {
		e.style.display = 'block';
	}
}

function setIDClass(id, theClass) {
	var e = document.getElementById(id);
	if (e) {
		e.className = theClass;
	}
}