// ShowHide Script
//
// David J. Harris - © Eclectic Networks 2002-2005
//
// Parameters:
// imageExpand - image to display when table is open/expanded
// imageCollapse - image to display when table is closed/retracted
// targetID - id of the table row that is opened/closed or expanded/retracted
// buttonID - id of the button that controls the row that is opened/closed or expanded/retracted
//
function ShowHide(imageExpand, imageCollapse, targetID, buttonID) {
	if ( document.getElementById )
	{
		var target = document.getElementById( targetID );
		if ( target != null )
		{
			target.style.display = ( target.style.display != "none" ) ? "none" : "";
		}
		if ( imageCollapse != "" )
		{
			var imageButton = document.getElementById( buttonID );
			if ( imageButton != null )
			{
				imageButton.src = ( target.style.display != "none" ) ? imageCollapse : imageExpand;
			}
		}
		return false;
	}
	return true;
}

