function _HP(e)
{
	try
	{
		e.oBorderColour = e.style.borderColor;
		e.style.borderColor = HighlightColour;
		
		// Need to find the parents first child so that
		// we can also turn the star on.
		var starCol = e.parentElement.firstChild;
		starCol.style.backgroundImage = 'url(' + ProductStarImgThemeBGHighlight + ')';
		
		var tS = FindChildRecursive(e, 'SPAN');
		if(tS != null)
		{
			tS.oColour = tS.style.color;
			tS.style.color = HighlightColour;
		}
	}
	catch(e){}
};

function _UP(e)
{
	try
	{
		if(e.oBorderColour != null)
		{
			e.style.borderColor = e.oBorderColour;
			e.oBorderColour = null;
		}
		
		var starCol = e.parentElement.firstChild;
		starCol.style.backgroundImage = 'url(' + ProductStarImgThemeBGOff + ')';
		
		var tS = FindChildRecursive(e, 'SPAN');
		if(tS != null)
		{
			tS.style.color = tS.oColour;
			tS.oColour = null;
		}
	}
	catch(e){}
};

function _HC(e)
{
	try
	{
		e.oBorderColour = e.style.borderColor;
		e.style.borderColor = HighlightColour;
		
		var tS = FindChildRecursive(e, 'SPAN');
		if(tS != null)
		{
			tS.oColour = tS.style.color;
			tS.style.color = HighlightColour;
		}
	}
	catch(e){}
};

function _UC(e)
{
	try
	{
		if(e.oBorderColour != null)
		{
			e.style.borderColor = e.oBorderColour;
			e.oBorderColour = null;
		}
		
		var tS = FindChildRecursive(e, 'SPAN');
		if(tS != null)
		{
			tS.style.color = tS.oColour;
			tS.oColour = null;
		}
	}
	catch(e){}
};

function FindChildRecursive(obj, tag, attrName, attrVal)
{
	var ret = null;
	
	// Find the text link using the DOM
	for(var i=0; i < obj.children.length; i++)
	{
		var child = obj.children[i];
		if(child.tagName == tag)
		{
			if(attrName != null && attrVal != null)
			{
				if(eval('child.' + attrName) == attrVal)
				{
					ret = child;
				}
			}
			else
			{
				// This supports just looking for a tag
				ret = child;
			}
		}
		
		if(ret == null)
		{
			ret = FindChildRecursive(child, tag, attrName, attrVal);
		}
	}
	return ret;
};
