/* -- This function processes the left navigational system: --------------------------------------------- */

function leftNavHighlighter(highlightID)
{
	// BEGIN: Left nav highlight styles.
	var fontColor = "#963";													// Use CSS style color values.
	var fontWeight = "bold";												// To unbold, set this to "normal".
	var textDecoration = "none";											// The highlighted first-tier and second-tier <LI> items should not appear to be links (i.e., this is functioning as a bread-crumb list).
	var firstTierBulletImage = "no-repeat url(/images/leaf.gif) 0px 11px";	// The location of the leaf graphic for first-tier list items.
	var secondTierBulletImage = "no-repeat url(/images/leaf.gif) 0px 5px";	// The location of the leaf graphic for second-tier list items.
	// END: Left nav highlight styles.
	
	// Get pointers to nearby HTML elements:
	var curr = document.getElementById(highlightID);  	// "curr" could point to a either a <UL>, first-tier <LI>, or second-tier <LI>.
	var child = curr.firstChild;						// The first child of the current element.
	var par = curr.parentNode;							// The parent element of the current element.
	var gpar = par.parentNode;							// The grand parent element of the current element.
	var ggpar = gpar.parentNode;						// The great grand parent element of the current element.
	
	
	if (curr.className === "leftNavList") 
	{
		// Assert: the current element is an outer <UL> (which does not get a leaf graphic nor does it change color).
		
		curr.style.display = "block";	// Only need to make this section of the left nav visible.
	}
	else if (par.className === "leftNavList")
	{
		// Assert: the current element is a first-tier <LI>.
		
		// Display left nav section:
		par.style.display = "block";
		
		// Change the style of the <A> tag within the <LI> tag:
		child.style.color = fontColor;	
		child.style.fontWeight = fontWeight;
		child.removeAttribute("href");
		child.style.textDecoration = textDecoration;	// Stripping out the "href" attribute doesn't kill the global CSS anchor tag underline style, so set it to none here.				
		
		// Place the leaf graphic for the current <LI> tag:
		curr.style.background = firstTierBulletImage;
	}
	else if (par.className === "leftSubNavList")
	{
		// Assert: the current element is a second-tier <LI> element.
		
		// Display left nav section:
		ggpar.style.display = "block";	
		
		// Change the style of the <A> tag within the <LI> tag:
		child.style.color = fontColor;	
		child.style.fontWeight = fontWeight;
		child.removeAttribute("href");
		child.style.textDecoration = textDecoration;	// Stripping out the "href" attribute doesn't kill the global CSS anchor tag underline style, so set it to none here.				
		
		// Place the leaf graphic for the current <LI> tag:
		curr.style.background = secondTierBulletImage;
	}
}