// Expand and collapse manager

function excolToggle( oParentEl, szSpecPath, szOmegaID )
{	
	//	alert(oParentEl.src);
	// get the parent element
	oParentNode= oParentEl.parentNode.parentNode.parentNode;
	
	if (szSpecPath)
	{
		szPath = szSpecPath;
	}
	else
	{
		szPath = "images/";
	}
	
	// Find the next sibling
	for ( bFound=0, oParentNode = oParentNode.nextSibling; oParentNode; oParentNode = oParentNode.nextSibling )
	{
		// break if the next body is found
		if (oParentNode.className == "cBody")
		{
			bFound = 1;
			break;
		}
	}
	
	if (!bFound)
	{
		return;
	}
	
	//alert(oParentEl.src);
	
	if (oParentNode.style.display != "block")
	{
		oParentNode.style.display = "block";
		oParentEl.src = szPath + "excol-up.gif";
	}
	else
	{
		oParentNode.style.display = "none";
		oParentEl.src = szPath + "excol-down.gif";
	}
	
	oParentEl.blur();
	
	// If there's an Omega ID, then find the element and toggle it
	if (szOmegaID)
	{
		elOmega = document.getElementById(szOmegaID);
		
		if (elOmega)
		{
			excolToggle(elOmega, szPath);
		}
	}
}