// JavaScript Document
    function checkfrm()
    {
            /*
			if (document.getElementById("keyword").value  != '')
            {
               var myk = document.getElementById("keyword").value.split("-");
                for(var i=0;i<myk.length;i++)
                {
                     if(i > 0 )
                        keyword = keyword + '-' + myk[i];
                     else
                        keyword = myk[i];
                }    
                for( i = 0; i < 5;i++)
                   keyword = keyword.replace(' ','-');
                   keyword = keyword.replace('/','-');
                window.location = "http://www.nutrovita.com/search/"+keyword+".htm";
	            //document.frmsearch.submit();
	            return false;
	        }
	        else
	        {
	            document.getElementById("keyword").focus();
	            return false;
	        }
			*/

			if (document.frmsearch.keyword.value.length == 0)	
			{
				alert("Please enter keyword to search");
				document.frmsearch.keyword.focus();
				return false;
			}

    }

/*    function ShowHideCoupon(bit)
    {
		if (bit == 1)
		{
			document.getElementById("DiscountCoupon").className = "DiscountCouponShow";
		}
		else if (bit == 0)
		{
			document.getElementById("DiscountCoupon").className = "DiscountCouponHide";			
		}
    }
*/    

function CreateBookmarkLink() {
title = document.title;
url = document.location.href;
if (window.sidebar) { // Mozilla Firefox Bookmark
window.sidebar.addPanel(title, url,"")
return false;
} else if( window.external ) { // IE Favorite
window.external.AddFavorite(url,title)
return false
}
else if(window.opera && window.print) { // Opera Hotlist
return false;}
}

function showcolors(id,bit)
{
if (bit==1)
{
document.getElementById(id).style.color = "#FFFFFF";
document.getElementById(id).style.background = "#336699" ;
}
else
{
document.getElementById(id).style.color = "#17127F";
document.getElementById(id).style.background = "#FFFFFF";
}

}

function showvisiblityhead(mydiv)
{
document.getElementById(mydiv).style.visibility = "visible";
}
function unvisibiliy(mydiv)
{
document.getElementById(mydiv).style.visibility = "hidden";
}

function mainlinks(getid,bit)
{

if(bit==1)
{
	document.getElementById(getid).style.color = "#FFFFFF";
}
else
{
	document.getElementById(getid).style.color = "#17127F";
}
}

function childstores(thisid,bit)
{
	if (bit == 1)
	{
	document.getElementById(thisid).style.backgroundColor = "#E7E7E7";
	}
	else
	{
	document.getElementById(thisid).style.backgroundColor = "#FFFFFF" ;
	}
}

function Maintdbg(tdid,bit)
{
if(bit == 1)
{
document.getElementById(tdid).style.backgroundColor = "#336699";
}
else
{
document.getElementById(tdid).style.backgroundColor = "";
}
}

function OpenReference(RDID, Section)
{
	window.open("/References.asp?Rdid=" + RDID + "#" + Section, "", 'scrollbars,width=800,height=200,left=100, top=150');
}

