function changeStyle(oElement, sPropertyName, sNewValue)
{
	if (oElement != false) {
		// get element style attribute
		oStyle = oElement.style;
		// apply new style value to provided property
		eval("oStyle." + sPropertyName + " = '" + sNewValue + "'");
	}
}

function getStyle(oElement, sPropertyName)
{
	var sReturn = false;
	
	if (oElement != false) {
		oStyle = oElement.style;
		sReturn = eval("oStyle." + sPropertyName);
	}
	
	return sReturn;
}

/* testimonials content swap */

function showContent(iHighlightId)
{
	showContentBox(iHighlightId);
	rollColorBox(iHighlightId);
}

function handleDescriptions(iHighId, sState)
{
	iDescriptionId = iHighId - 1;
	oDescriptionContainer = getThis("dhtmlHover");
	
	if (oDescriptionContainer != false) {
		oDescriptions = oDescriptionContainer.getElementsByTagName("div");
		
		for (i = 0; i < oDescriptions.length; i++) {
			changeStyle(oDescriptions[i], "visibility", "hidden");
		}
		if (sState == "on") {
			changeStyle(oDescriptions[iDescriptionId], "visibility", "visible");
		}
	}
}

function rollColorBox(iBoxId)
{	
	iLinkPosition = iBoxId - 1;
	oLinkContainer = getThis("servicesContentNav");
	oLinks = oLinkContainer.getElementsByTagName("a");
	
	if (oLinks != false) {
		for (i = 0; i < oLinks.length; i++) {
			oLinks[i].className = "regular";
		}
		oLinks[iLinkPosition].className = "selected";
	}
}

function showContentBox(iBucketId)
{
	sBucketId = "bucket" + iBucketId;
	clearContentBoxes();
	oBox = getThis(sBucketId);
	
	if (oBox != false) {
		changeStyle(oBox, "display", "block");
	}
}

function clearColorBoxes()
{
	oBoxContainer = getThis("servicesContentNav");
	
	if (oBoxContainer != false) {
		oBoxes = oBoxContainer.getElementsByTagName("a");
		
		for (i = 0; i < oBoxes.length; i++) {
			oBoxes[i].className = "regular";
		}
	}
}

function clearContentBoxes()
{
	if (document.getElementById) {
		for (i = 0; i < 4; i++) {
			sBox = "bucket" + i;
			oBox = document.getElementById(sBox).style;
			oBox.display = "none";
		}
	}
}