function getCat(catId,catTitle)
{
	var catId, catTitle;
    document.getElementById("cid").value=catId;
    document.getElementById("catTitle").innerHTML=catTitle;
    if(document.getElementById("quckfind").value!='Quick Find');
    {
    document.getElementById("quckfind").value='Quick Find'
    }
catAjax(catId);
    
    
    
}

function getCatPerson(catId,catTitle)
{
	var catId, catTitle;
    document.getElementById("cid").value=catId;
    document.getElementById("catTitle").innerHTML=catTitle;
    if(document.getElementById("quckfind").value!='Quick Find');
    {
    document.getElementById("quckfind").value='Quick Find'
    }

	var styleType0 = styleType1 = styleType2 = styleType3 = styleType4 = styleType5 = styleType6 = styleType7 = styleType8= "";
	var imgleft0 = imgleft1 = imgleft2 = imgleft3 = imgleft4 = imgleft5 = imgleft6 = imgleft7 = imgleft8 ="";
	var imgright0 = imgright1 = imgright2 = imgright3 = imgright4 = imgright5 = imgright6 = imgright7 = imgright8 ="";

	if(catId == 0)	{styleType0="class=details"; imgleft0 = "<img src='images/left_curve.jpg' width='7' height='17' border='0' alt='' align='left'>";imgright0 = "<img src='images/right_curve.jpg' width='7' height='17' border='0' alt='' >";}
	if(catId == 1)	{styleType1="class=details"; imgleft1 = "<img src='images/left_curve.jpg' width='7' height='17' border='0' alt='' align='left'>";imgright1 = "<img src='images/right_curve.jpg' width='7' height='17' border='0' alt='' >";}	
	if(catId == 2)	{styleType2="class=details"; imgleft2 = "<img src='images/left_curve.jpg' width='7' height='17' border='0' alt='' align='left'>";imgright2 = "<img src='images/right_curve.jpg' width='7' height='17' border='0' alt='' >";}	
	if(catId == 3)	{styleType3="class=details"; imgleft3 = "<img src='images/left_curve.jpg' width='7' height='17' border='0' alt='' align='left'>";imgright3 = "<img src='images/right_curve.jpg' width='7' height='17' border='0' alt='' >";}
	if(catId == 4)	{styleType4="class=details"; imgleft4 = "<img src='images/left_curve.jpg' width='7' height='17' border='0' alt='' align='left'>";imgright4 = "<img src='images/right_curve.jpg' width='7' height='17' border='0' alt='' >";}
	if(catId == 5)	{styleType5="class=details"; imgleft5 = "<img src='images/left_curve.jpg' width='7' height='17' border='0' alt='' align='left'>";imgright5 = "<img src='images/right_curve.jpg' width='7' height='17' border='0' alt='' >";}
	if(catId == 6)	{styleType6="class=details"; imgleft6 = "<img src='images/left_curve.jpg' width='7' height='17' border='0' alt='' align='left'>";imgright6 = "<img src='images/right_curve.jpg' width='7' height='17' border='0' alt='' >";}
	if(catId == 7)	{styleType7="class=details"; imgleft7 = "<img src='images/left_curve.jpg' width='7' height='17' border='0' alt='' align='left'>";imgright7 = "<img src='images/right_curve.jpg' width='7' height='17' border='0' alt='' >";}
	if(catId == 8)	{styleType8="class=details"; imgleft8 = "<img src='images/left_curve.jpg' width='7' height='17' border='0' alt='' align='left'>";imgright8 = "<img src='images/right_curve.jpg' width='7' height='17' border='0' alt='' >";}


/*    document.getElementById("sub_menu_personality").innerHTML="<table  cellpadding='0' cellspacing='0'><tr><td  "+styleType0+">"+imgleft0+"<div><a href='javascript:showHint(\"\",\"0\",\"0\")' onclick='getCatPerson(\"0\",\"Featured\");'>Featured</a> </div>"+imgright0+"</td><td class='space'><img src='images/spacer.gif' width='1' height='1' border='0' alt=''></td><td "+styleType1+">"+imgleft1+"<div><a href='javascript:showHint(\"\",\"0\",\"1\")' onclick='getCatPerson(\"1\",\"Food Network\");'>Food Network</a></div>"+imgright1+"</td><td class='space'><img src='images/spacer.gif' width='1' height='1' border='0' alt=''></td><td "+styleType2+">"+imgleft2+"<div><a href='javascript:showHint(\"\",\"0\",\"2\")' onclick='getCatPerson(\"2\",\"Top Hits\");'>Top Hits</a></div>"+imgright2+"</td><td class='space'><img src='images/spacer.gif' width='1' height='1' border='0' alt=''></td><td "+styleType3+">"+imgleft3+"<div><a href='javascript:showHint(\"\",\"0\",\"3\")' onclick='getCatPerson(\"3\",\"Chef & Culinary\");'>Chef & Culinary</a></div>"+imgright3+"</td><td class='space'><img src='images/spacer.gif' width='1' height='1' border='0' alt=''></td><td "+styleType4+">"+imgleft4+"<div><a href='javascript:showHint(\"\",\"0\",\"4\")' onclick='getCatPerson(\"4\",\"Wine & Spirits\");'>Wine & Spirits</a></div>"+imgright4+"</td><td class='space'><img src='images/spacer.gif' width='1' height='1' border='0' alt=''></td><td "+styleType5+">"+imgleft5+"<div><a href='javascript:showHint(\"\",\"0\",\"5\")' onclick='getCatPerson(\"5\",\"Last Name\");'>Last Name</a></div>"+imgright5+"</td><td class='space'><img src='images/spacer.gif' width='1' height='1' border='0' alt=''></td><td "+styleType6+">"+imgleft6+"<div><a href='javascript:showHint(\"\",\"0\",\"6\")' onclick='getCatPerson(\"6\",\"First Name\");'>First Name</a></div>"+imgright6+"</td><td class='space'><img src='images/spacer.gif' width='1' height='1' border='0' alt=''></td><td "+styleType7+">"+imgleft7+"<div><a href='javascript:showHint(\"\",\"0\",\"7\")' onclick='getCatPerson(\"7\",\"Just Added\");'>Just Added</a></div>"+imgright7+"</td></tr></table>";*/
    
document.getElementById("sub_menu_personality").innerHTML="<table  cellpadding='0' cellspacing='0'><tr><td  "+styleType0+">"+imgleft0+"<div><a href='javascript:showHint(\"\",\"0\",\"0\")' onclick='getCatPerson(\"0\",\"Featured\");'>Featured</a> </div>"+imgright0+"</td><td class='space'><img src='images/spacer.gif' width='1' height='1' border='0' alt=''></td><td "+styleType1+">"+imgleft1+"<div><a href='javascript:showHint(\"\",\"0\",\"1\")' onclick='getCatPerson(\"1\",\"Food Network\");'>Food Network</a></div>"+imgright1+"</td><td class='space'><img src='images/spacer.gif' width='1' height='1' border='0' alt=''></td><td class='space'><img src='images/spacer.gif' width='1' height='1' border='0' alt=''></td><td "+styleType3+">"+imgleft3+"<div><a href='javascript:showHint(\"\",\"0\",\"3\")' onclick='getCatPerson(\"3\",\"Chef & Culinary\");'>Chef & Culinary</a></div>"+imgright3+"</td><td class='space'><img src='images/spacer.gif' width='1' height='1' border='0' alt=''></td><td "+styleType4+">"+imgleft4+"<div><a href='javascript:showHint(\"\",\"0\",\"4\")' onclick='getCatPerson(\"4\",\"Wine & Spirits\");'>Wine & Spirits</a></div>"+imgright4+"</td><td class='space'><img src='images/spacer.gif' width='1' height='1' border='0' alt=''></td><td "+styleType5+">"+imgleft5+"<div><a href='javascript:showHint(\"\",\"0\",\"5\")' onclick='getCatPerson(\"5\",\"Last Name\");'>Last Name</a></div>"+imgright5+"</td><td class='space'><img src='images/spacer.gif' width='1' height='1' border='0' alt=''></td><td "+styleType6+">"+imgleft6+"<div><a href='javascript:showHint(\"\",\"0\",\"6\")' onclick='getCatPerson(\"6\",\"First Name\");'>First Name</a></div>"+imgright6+"</td><td class='space'><img src='images/spacer.gif' width='1' height='1' border='0' alt=''></td><td "+styleType7+">"+imgleft7+"<div><a href='javascript:showHint(\"\",\"0\",\"7\")' onclick='getCatPerson(\"7\",\"Just Added\");'>Just Added</a></div>"+imgright7+"</td><td class='space'><img src='images/spacer.gif' width='1' height='1' border='0' alt=''></td><td "+styleType8+">"+imgleft8+"<div><a href='javascript:showHint(\"\",\"0\",\"8\")' onclick='getCatPerson(\"8\",\"All\");'>All</a></div>"+imgright8+"</td></tr></table>";    

	//alert(document.getElementById("sub_menu_personality").innerHTML);
  showHint("","0",catId);  
    
}

/****************************************/
function showHintCat(query)
{
var catId,pageId,query;
	catId=document.getElementById("cid").value;
	pageId=document.getElementById("pageId").value;

showHint(query,pageId,catId);
}
/************************************************/
var win = null;
function PopWindow(mypage,myname,w,h,scroll){
LeftPosition = (screen.width) ? (screen.width-w)/2 : 0;
TopPosition = (screen.height) ? (screen.height-h)/2 : 0;
settings ='height='+h+',width='+w+',top='+TopPosition+',left='+LeftPosition+',scrollbars='+scroll+',resizable'
win = window.open(mypage,myname,settings)
}
/************************************************/
function showHide(boxName) {
	//set the object to a variable, so we can simplfy the code
	theBox = document.getElementById(boxName);
	//if the class equals our visible code, set the class to the hidden box style, else set the class to the visible box style
	if (theBox.className == "boxVisible") {
		theBox.className = "boxHidden";
	} else {
		theBox.className = "boxVisible";
	}
}
