//open the image popup window
function openImg(urls)
{
	window.open(urls, 'img', 'width=396, height=219');
}
//open google maps popup window
function openMap(urls)
{
	window.open(urls, 'map', 'width=550, height=396');
}
//open tellafriend popup window
function openEmailFriend(urls)
{
	window.open(urls, 'friend', 'width=550, height=345');
}
//open leave a message window
function openMessage(urls)
{
	window.open(urls, 'msg', 'width=550, height=475');
}
//open a new window
function openwin(url, p1, p2)
{
	window.open(url, p1, p2);
}

// drop down menus
window.name="main";
sfHover = function() {
	var sfEls = document.getElementById("mainNav").getElementsByTagName("li");
	for (var i=0; i<sfEls.length; i++) {
		sfEls[i].onmouseover=function() {
			this.className+=" sfhover";
		}
		sfEls[i].onmouseout=function() {
			this.className=this.className.replace(new RegExp(" sfhover\\b"), "");
		}
	}
}

if (window.attachEvent) window.attachEvent("onload", sfHover);

// product image layers
function showImg(cid)
{
	for (var i=0; i<10; i++)
	{
		var obj = document.getElementById('pcat_'+i);
		if (obj)
		{
			if (i == cid)
			{
				obj.style.display = '';
			}
			else
			{
				obj.style.display = 'none';
			}
		}
		else
			break;
	}
}

function MM_jumpMenu(targ,selObj,restore){ //v3.0
  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
  if (restore) selObj.selectedIndex=0;
}