

function ChangeLinkColor(WhichObj, Color, bccolor)
{
	WhichObj.color = Color;
	if (bccolor != 'none')
	{
		WhichObj.style.backgroundColor = bccolor;
	}
}

function MoveLayer(MovingLayer)
{
	var intOldTop = document.body.scrollTop;
	//alert(intOldTop);
	var intNewTop = intOldTop + 0;
	document.getElementById(MovingLayer).style.top = intNewTop;
}



function CloseNewStuffArea()
{
	document.getElementById("NewStuffAreaDiv").style.display = "none";
	MoveLayer('AccountLayer');
}
function OpenNewStuffArea()
{
	NewStuffAraeIFrame.location.replace("NewStuff.asp");
	document.getElementById("NewStuffAreaDiv").style.display = "block";
}

function GoToPage(strRequestedURL)
{
	top.MainAraeIFrame.document.location.replace("CheckChookie.asp?rurl=" + strRequestedURL);
}

function GoToPageFromPopUpWindow(strRequestedURL)
{
	window.opener.top.document.location.replace(strRequestedURL);
}

function GoToPageWithOutLogin(strRequestedURL)
{
	top.MainAraeIFrame.document.location.replace(strRequestedURL);
}

function GoToSectionPage(strRequestedURL)
{
	top.document.location.replace(strRequestedURL);
}

function GoToPopUpPage(Page)
{
	window.open(Page, "NewWin", "toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=yes, resizable=no, width=0, height=0");
}

function GoToFullScreenPopUpPage(Page)
{
	window.open(Page);
}

function GoToPopUpPageWithName(Page, WindowName)
{
	window.open(Page, WindowName, "toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=yes, resizable=no, width=0, height=0");
}


function ShowHideShoppingCartLayer()
{
	if (document.getElementById("ShoppingCartDiv").style.visibility == "hidden")
	{
		ShowShoppingCartLayer();
		HideContactUsLayer();
	}
	else
	{
		HideShoppingCartLayer();
	}
}

function ShowHideContactUsLayer()
{
	if (document.getElementById("ContactUsDiv").style.visibility == "hidden")
	{
		ShowContactUsLayer();
		HideShoppingCartLayer();
	}
	else
	{
		HideContactUsLayer();
	}
}

function ShowContactUsLayer()
{
	document.getElementById("ContactUsDiv").style.visibility = "visible";
	document.getElementById("ContactUsFont").style.borderTop = "1px #000000 solid";
	document.getElementById("ContactUsFont").style.borderRight = "1px #000000 solid";
	document.getElementById("ContactUsFont").style.borderLeft = "1px #000000 solid";
}

function HideContactUsLayer()
{
	document.getElementById("ContactUsDiv").style.visibility = "hidden";
	document.getElementById("ContactUsFont").style.borderTop = "0px #000000 solid";
	document.getElementById("ContactUsFont").style.borderRight = "0px #000000 solid";
	document.getElementById("ContactUsFont").style.borderLeft = "0px #000000 solid";
}

function ShowShoppingCartLayer()
{
	document.getElementById("ShoppingCartDiv").style.visibility = "visible";
	document.getElementById("ShoppingCartFont").style.borderTop = "1px #000000 solid";
	document.getElementById("ShoppingCartFont").style.borderRight = "1px #000000 solid";
	document.getElementById("ShoppingCartFont").style.borderLeft = "1px #000000 solid";
}

function HideShoppingCartLayer()
{
	document.getElementById("ShoppingCartDiv").style.visibility = "hidden";
	document.getElementById("ShoppingCartFont").style.borderTop = "0px #000000 solid";
	document.getElementById("ShoppingCartFont").style.borderRight = "0px #000000 solid";
	document.getElementById("ShoppingCartFont").style.borderLeft = "0px #000000 solid";
}



function MenuRollOver(WhichTableCell, WhichMenu)
{
	WhichTableCell.style.backgroundColor = "#FFFFFF";
	document.getElementById(WhichMenu).color = "#000000";
}

function MenuRollOut(WhichTableCell, WhichMenu)
{
	WhichTableCell.style.backgroundColor = "";
	document.getElementById(WhichMenu).color = "#FFFFFF";
}



function getCookie(name) 
{
	var dc = document.cookie;
 	var prefix = name + "=";
  	var begin = dc.indexOf("; " + prefix);
 	if (begin == -1) 
	{
    		begin = dc.indexOf(prefix);
    		if (begin != 0) return null;
  	}
	else
    		begin += 2;
  		var end = document.cookie.indexOf(";", begin);
 	if (end == -1)
    	end = dc.length;
  return unescape(dc.substring(begin + prefix.length, end));
}