function popupMailer(sSite, sPage, sItemName, sItemID)
{
	var sURL = "../EmailArticle.aspx?site=" + sSite + "&page=" + sPage + "&name=" + sItemName + "&value=" + sItemID;
	popupTellAFriend(sURL);
}

function popupTellAFriend(sURL)
{
	popup(sURL, "popup", "toolbar=no,menubar=no,location=no,scrollbars=yes,resizable=no,width=715,height=490");
}

function popup(url, name, features)
{
	var win = window.open(url, name, features);
	win.focus();
}


			
if (document.images) {
		b1on = new Image(); 
		b1on.src = "../images/b1on.gif"; 
		b2on = new Image();      
		b2on.src = "../images/b2on.gif"; 
		b3on = new Image();      
		b3on.src = "../images/b3on.gif"; 
		
		nav_diaon = new Image();      
		nav_diaon.src = "../images/nav_dia_on.gif"; 
		
		nav_whereon = new Image(); 
		nav_whereon.src = "../images/nav_where_on.gif"; 
		nav_recon = new Image();      
		nav_recon.src = "../images/nav_rec_on.gif"; 
		nav_specion = new Image(); 
		nav_specion.src = "../images/nav_spec_on.gif"; 
		
		b1off = new Image(); 
		b1off.src = "../images/b1off.gif"; 
		b2off = new Image();      
		b2off.src = "../images/b2off.gif"; 
		b3off = new Image();      
		b3off.src = "../images/b3off.gif";
		
		nav_diaoff = new Image();      
		nav_diaoff.src = "../images/nav_dia_off.gif"; 
		
		nav_whereoff = new Image(); 
		nav_whereoff.src = "../images/nav_where_off.gif"; 
		nav_recoff = new Image();      
		nav_recoff.src = "../images/nav_rec_off.gif"; 
		nav_specioff = new Image(); 
		nav_specioff.src = "../images/nav_spec_off.gif"; 
		
	}

	function imageOff(imgName) {
		if (document.images) {
			document[imgName].src = eval(imgName + "off.src");
		}
	}
			
	function imageOn(imgName) {
		if (document.images) {
			document[imgName].src = eval(imgName + "on.src");
		}
	}	
	

// TOPNAV HOVER FOR IE
tnHover = function() {
	var topNav = document.getElementById("topnav");
	if (topNav == null) return;
	
	var tnEls = topNav.getElementsByTagName("LI");
	if (tnEls == null) return;
	
	for (var i=0; i<tnEls.length; i++) {
		tnEls[i].onmouseover=function() {
			this.className+=" tnhover";
		}
		tnEls[i].onmouseout=function() {
			this.className=this.className.replace(new RegExp(" tnhover\\b"), "");
		}
	}
}
if (window.attachEvent) window.attachEvent("onload", tnHover);

	
// DHTML navs	

isNS4 = (document.layers) ? true : false;
isIE4 = (document.all && !document.getElementById) ? true : false;
isIE5 = (document.all && document.getElementById) ? true : false;
isNS6 = (!document.all && document.getElementById) ? true : false;

divSupported = (isNS4 || isIE4 || isIE5 || isNS6) ? true : false;
	
var onDiv;
var hideMenu = null;

function Hide(div){
	if (divSupported) 
	{
		if(isIE4)
			eval('document.all["' + div + '"].style' + '.visibility = "hidden"');
			//eval('document.all.'+ div +'.style.visibility="hidden"');
		if(isIE5)
			eval('document.all["' + div + '"].style' + '.visibility = "hidden"');
			//eval('document.all.'+div+'.style.visibility="hidden"');
		if(isNS4)
			eval('document.layers["' + div + '"]' + '.visibility = "hide"');
			//eval('document.layers.'+div+'.visibility="hide"');
		if(isNS6)
			eval('document.getElementById("' + div + '").style' + '.visibility = "hidden"');
			//eval('document.getElementById.'+div+'.visibility="hide"');
		}
}
function Show(div){
	if (divSupported) 
	{
		if(isIE4)
			eval('document.all["' + div + '"].style' + '.visibility = "visible"');
			//eval('document.all.'+div+'.style.visibility="visible"');
			onDiv = div
		if(isIE5)
			eval('document.all["' + div + '"].style' + '.visibility = "visible"');
			//eval('document.all.'+div+'.style.visibility="visible"');
			onDiv = div
		if(isNS4)
			eval('document.layers["' + div + '"]' + '.visibility = "inherit"');
			//eval('document.layers.'+div+'.visibility="inherit"');
			onDiv = div
		if(isNS6)
			eval('document.getElementById("' + div + '").style' + '.visibility = "visible"');
			//eval('document.getElementById.'+div+'.visibility="inherit"');
			onDiv = div
		}
}


function imgOn(Num) {
	hideAll();
	if (document.images) {
		document.images["b" +Num].src = eval("b" +Num+ "on.src")
	}
}

function imgOff(Num) {
	if (document.images) {
		document.images["b" +Num].src = eval("b" +Num+ "off.src")
	}
}

//MenuMouseOver
function mImgOn(divNum,Num) {
clearTimeout(hideMenu);
	if (document.images) {
		if(isIE4){
		document.images["m" +divNum+ "b" +Num].src = eval("m" +divNum+ "b" +Num+ "on.src")
		}
		if(isIE5){
		document.images["m" +divNum+ "b" +Num].src = eval("m" +divNum+ "b" +Num+ "on.src")
		}	
		if(isNS4){
		document.images["m" +divNum+ "b" +Num].src = eval("m" +divNum+ "b" +Num+ "on.src")
		}
		if(isNS6){
		document.images["m" +divNum+ "b" +Num].src = eval("m" +divNum+ "b" +Num+ "on.src")
		}
	}
}

function mImgOff(divNum,Num) {
	if (document.images) {
		if(isIE4){
		document.images["m" +divNum+ "b" +Num].src = eval("m" +divNum+ "b" +Num+ "off.src")
		}
		if(isIE5){
		document.images["m" +divNum+ "b" +Num].src = eval("m" +divNum+ "b" +Num+ "off.src")
		}
		if(isNS4){
		document.images["m" +divNum+ "b" +Num].src = eval("m" +divNum+ "b" +Num+ "off.src")
		}
		if(isNS6){
		document.images["m" +divNum+ "b" +Num].src = eval("m" +divNum+ "b" +Num+ "off.src")
		}
	}
hideMenu=setTimeout('hideAll()',100)
}

function hideAll(){
Hide('m1');
Hide('m2');
Hide('m3');
Hide('m4');
Hide('m5');
Hide('m6');
}

if(document.images){
for (i=1; i<=16; i++)
{
eval("b"+i+"off = new Image()");eval("b"+i+"off.src = '../images/b"+i+"off.gif'");
eval("b"+i+"on = new Image()");eval("b"+i+"on.src = '../images/b"+i+"on.gif'");
eval("m1b"+i+"off = new Image()");eval("m1b"+i+"off.src = '../images/m1b"+i+"off.gif'");
eval("m1b"+i+"on = new Image()");eval("m1b"+i+"on.src = '../images/m1b"+i+"on.gif'");
} 
for (i=1; i<=16; i++)
{
eval("m2b"+i+"off = new Image()");eval("m2b"+i+"off.src = '../images/m2b"+i+"off.gif'");
eval("m2b"+i+"on = new Image()");eval("m2b"+i+"on.src = '../images/m2b"+i+"on.gif'");
}
for (i=1; i<=16; i++)
{
eval("m3b"+i+"off = new Image()");eval("m3b"+i+"off.src = '../images/m3b"+i+"off.gif'");
eval("m3b"+i+"on = new Image()");eval("m3b"+i+"on.src = '../images/m3b"+i+"on.gif'");
}

}

// Load Different StyleSheet for Browsers

if(isIE4){
document.write('<link rel=stylesheet href=includes/common.css type=text/css>')
}
if(isIE5){
document.write('<link rel=stylesheet href=includes/common.css type=text/css>')
}
if(isNS4){
document.write('<link rel=stylesheet href=includes/common_ns.css type=text/css>')
}
if(isNS6){
document.write('<link rel=stylesheet href=includes/common_ns.css type=text/css>')
}

function popWin(url,height,width,toolbar,menubar,locationbar,scroll,resize,status,name) {

	var Browser
	var spec

	spec = "status="+status+",toolbar="+toolbar+",menubar="+menubar+",location="+locationbar+",scrollbars="+scroll+",resizable="+resize+",height="+height+",width="+width;
	
	remote = window.open(url, name, spec);
	remote.focus();
	remote.location.href = url;
}
		
//****************************
//** RECIPES PAGE - START ****
//****************************	
	function changeClass(divID, newClassName){
		var obj = document.getElementById(divID);
		if(obj != null)
			document.getElementById(divID).className  = newClassName;
	}
	
	function changeCard(cardNum){
		changeClass('recipeNav','n_'+cardNum);
		changeClass('recipeContent','c_'+cardNum);
		showCard('card'+cardNum);
	}
	
	function curNav(whichNav){
		if (whichNav == 1){
			changeClass('recipeRow1','bottomRow');
			changeClass('recipeRow2','topRow');
		}
		else if (whichNav == 2){
			changeClass('recipeRow1','topRow');
			changeClass('recipeRow2','bottomRow');
		}
	}
	
	function showCard(whichCard){
		if(document.getElementById('cardr000') != null)
			document.getElementById('cardr000').style.display = 'none';
		if(document.getElementById('cardr101') != null)
			document.getElementById('cardr101').style.display = 'none';
		if(document.getElementById('cardr102') != null)
			document.getElementById('cardr102').style.display = 'none';
		if(document.getElementById('cardr103') != null)
			document.getElementById('cardr103').style.display = 'none';
		if(document.getElementById('cardr104') != null)
			document.getElementById('cardr104').style.display = 'none';
		if(document.getElementById('cardr105') != null)
			document.getElementById('cardr105').style.display = 'none';
		if(document.getElementById('cardr201') != null)
			document.getElementById('cardr201').style.display = 'none';
		if(document.getElementById('cardr202') != null)
			document.getElementById('cardr202').style.display = 'none';
		if(document.getElementById('cardr203') != null)
			document.getElementById('cardr203').style.display = 'none';
		if(document.getElementById('cardr204') != null)
			document.getElementById('cardr204').style.display = 'none';
		if(document.getElementById('cardr205') != null)
			document.getElementById('cardr205').style.display = 'none';
		if(document.getElementById(whichCard) != null)
			document.getElementById(whichCard).style.display = 'block';
	}	
	
	function checkCardOnLoad(){
		var isTab = document.URL.indexOf('#');
		if (isTab != -1){ 
			currentTab = document.URL.substring(isTab+1, document.URL.length);
			
			if(currentTab == "Appetizers"){
				changeCard('r101');
				curNav(1);
			}else if(currentTab == "SaladsSoups"){
				changeCard('r102');
				curNav(1);
			}else if(currentTab == "PastaVegetarian"){
				changeCard('r103');
				curNav(1);
			}else if(currentTab == "Meats"){
				changeCard('r104');
				curNav(1);
			}else if(currentTab == "Seafood"){
				changeCard('r105');
				curNav(1);
			}else if(currentTab == "Beverages"){
				changeCard('r201');
				curNav(2);
			}else if(currentTab == "SaucesSalsas"){
				changeCard('r202');
				curNav(2);
			}else if(currentTab == "SideDishes"){
				changeCard('r203');
				curNav(2);
			}else if(currentTab == "Snacks"){
				changeCard('r204');
				curNav(2);
			}else if(currentTab == "Desserts"){
				changeCard('r205');
				curNav(2);
			}
		}
	}
	
	function switchContent(oldDiv, newDiv) {
		document.getElementById(oldDiv).style.display = 'none';
		document.getElementById(newDiv).style.display = 'block';
	}
	
//**************************
//** RECIPES PAGE - END ****
//**************************

	
		
		
//***********************************************************************************
//** Flash Sniffing/Inserter -- NEW -- Use this to fix IE graybox Issue -- START ****
//***********************************************************************************

/*  SWFObject v1.4: Flash Player detection and embed - http://blog.deconcept.com/swfobject/  */

if(typeof deconcept=="undefined"){var deconcept=new Object();}
if(typeof deconcept.util=="undefined"){deconcept.util=new Object();}
if(typeof deconcept.SWFObjectUtil=="undefined"){deconcept.SWFObjectUtil=new Object();}
deconcept.SWFObject=function(_1,id,w,h,_5,c,_7,_8,_9,_a,_b){
if(!document.createElement||!document.getElementById){return;}
this.DETECT_KEY=_b?_b:"detectflash";
this.skipDetect=deconcept.util.getRequestParameter(this.DETECT_KEY);
this.params=new Object();
this.variables=new Object();
this.attributes=new Array();
if(_1){this.setAttribute("swf",_1);}
if(id){this.setAttribute("id",id);}
if(w){this.setAttribute("width",w);}
if(h){this.setAttribute("height",h);}
if(_5){this.setAttribute("version",new deconcept.PlayerVersion(_5.toString().split(".")));}
this.installedVer=deconcept.SWFObjectUtil.getPlayerVersion(this.getAttribute("version"),_7);
if(c){this.addParam("bgcolor",c);}
var q=_8?_8:"high";
this.addParam("quality",q);
this.setAttribute("useExpressInstall",_7);
this.setAttribute("doExpressInstall",false);
var _d=(_9)?_9:window.location;
this.setAttribute("xiRedirectUrl",_d);
this.setAttribute("redirectUrl","");
if(_a){this.setAttribute("redirectUrl",_a);}};
deconcept.SWFObject.prototype={setAttribute:function(_e,_f){
this.attributes[_e]=_f;
},getAttribute:function(_10){
return this.attributes[_10];
},addParam:function(_11,_12){
this.params[_11]=_12;
},getParams:function(){
return this.params;
},addVariable:function(_13,_14){
this.variables[_13]=_14;
},getVariable:function(_15){
return this.variables[_15];
},getVariables:function(){
return this.variables;
},getVariablePairs:function(){
var _16=new Array();
var key;
var _18=this.getVariables();
for(key in _18){
_16.push(key+"="+_18[key]);}
return _16;
},getSWFHTML:function(){
var _19="";
if(navigator.plugins&&navigator.mimeTypes&&navigator.mimeTypes.length){
if(this.getAttribute("doExpressInstall")){this.addVariable("MMplayerType","PlugIn");}
_19="<embed type=\"application/x-shockwave-flash\" src=\""+this.getAttribute("swf")+"\" width=\""+this.getAttribute("width")+"\" height=\""+this.getAttribute("height")+"\"";
_19+=" id=\""+this.getAttribute("id")+"\" name=\""+this.getAttribute("id")+"\" ";
var _1a=this.getParams();
for(var key in _1a){_19+=[key]+"=\""+_1a[key]+"\" ";}
var _1c=this.getVariablePairs().join("&");
if(_1c.length>0){_19+="flashvars=\""+_1c+"\"";}
_19+="/>";
}else{
if(this.getAttribute("doExpressInstall")){this.addVariable("MMplayerType","ActiveX");}
_19="<object id=\""+this.getAttribute("id")+"\" classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" width=\""+this.getAttribute("width")+"\" height=\""+this.getAttribute("height")+"\">";
_19+="<param name=\"movie\" value=\""+this.getAttribute("swf")+"\" />";
var _1d=this.getParams();
for(var key in _1d){_19+="<param name=\""+key+"\" value=\""+_1d[key]+"\" />";}
var _1f=this.getVariablePairs().join("&");
if(_1f.length>0){_19+="<param name=\"flashvars\" value=\""+_1f+"\" />";}
_19+="</object>";}
return _19;
},write:function(_20){
if(this.getAttribute("useExpressInstall")){
var _21=new deconcept.PlayerVersion([6,0,65]);
if(this.installedVer.versionIsValid(_21)&&!this.installedVer.versionIsValid(this.getAttribute("version"))){
this.setAttribute("doExpressInstall",true);
this.addVariable("MMredirectURL",escape(this.getAttribute("xiRedirectUrl")));
document.title=document.title.slice(0,47)+" - Flash Player Installation";
this.addVariable("MMdoctitle",document.title);}}
if(this.skipDetect||this.getAttribute("doExpressInstall")||this.installedVer.versionIsValid(this.getAttribute("version"))){
var n=(typeof _20=="string")?document.getElementById(_20):_20;
n.innerHTML=this.getSWFHTML();
return true;
}else{
if(this.getAttribute("redirectUrl")!=""){document.location.replace(this.getAttribute("redirectUrl"));}}
return false;}};
deconcept.SWFObjectUtil.getPlayerVersion=function(_23,_24){
var _25=new deconcept.PlayerVersion([0,0,0]);
if(navigator.plugins&&navigator.mimeTypes.length){
var x=navigator.plugins["Shockwave Flash"];
if(x&&x.description){_25=new deconcept.PlayerVersion(x.description.replace(/([a-z]|[A-Z]|\s)+/,"").replace(/(\s+r|\s+b[0-9]+)/,".").split("."));}
}else{try{
var axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash");
for(var i=3;axo!=null;i++){
axo=new ActiveXObject("ShockwaveFlash.ShockwaveFlash."+i);
_25=new deconcept.PlayerVersion([i,0,0]);}}
catch(e){}
if(_23&&_25.major>_23.major){return _25;}
if(!_23||((_23.minor!=0||_23.rev!=0)&&_25.major==_23.major)||_25.major!=6||_24){
try{_25=new deconcept.PlayerVersion(axo.GetVariable("$version").split(" ")[1].split(","));}
catch(e){}}}
return _25;};
deconcept.PlayerVersion=function(_29){
this.major=parseInt(_29[0])!=null?parseInt(_29[0]):0;
this.minor=parseInt(_29[1])||0;
this.rev=parseInt(_29[2])||0;};
deconcept.PlayerVersion.prototype.versionIsValid=function(fv){
if(this.major<fv.major){return false;}
if(this.major>fv.major){return true;}
if(this.minor<fv.minor){return false;}
if(this.minor>fv.minor){return true;}
if(this.rev<fv.rev){return false;}return true;};
deconcept.util={getRequestParameter:function(_2b){
var q=document.location.search||document.location.hash;
if(q){
var _2d=q.indexOf(_2b+"=");
var _2e=(q.indexOf("&",_2d)>-1)?q.indexOf("&",_2d):q.length;
if(q.length>1&&_2d>-1){
return q.substring(q.indexOf("=",_2d)+1,_2e);
}}return "";}};
if(Array.prototype.push==null){
Array.prototype.push=function(_2f){
this[this.length]=_2f;
return this.length;};}
var getQueryParamValue=deconcept.util.getRequestParameter;
var FlashObject=deconcept.SWFObject; // for backwards compatibility
var SWFObject=deconcept.SWFObject;

//***********************************
//** Flash Sniffing/Inserter END ****
//***********************************
		
		
		
		
		
		
		
		
		
		
		
		
		
		
		
		
			
////////////////////////////////////////////////
// Get Browser & Platform //////////////////////
////////////////////////////////////////////////

//var Browser
//var platform
//var Version

//if (navigator.appVersion.lastIndexOf('PPC') != -1) {
//	platform = "Mac"; }
//else if (navigator.appVersion.lastIndexOf('Win') != -1) {
//	platform = "Win"; }

//if (navigator.appName.indexOf('Netscape') != -1) {
//	Browser = "NS"; }
//else if (navigator.appName.indexOf('Microsoft') != -1) {
//	Browser = "IE"; }

//if (parseInt(navigator.appVersion) < 5) {
//	Version = "4"; }
//else {
//	Version = "5"; }

//var thisBrowserVersion = Browser + Version;
//var thisBrowserPlatform = Browser + platform;
//var thisBrowserVersionPlatform = Browser + Version + platform;

/////////////////////////////////////////////////
//  ///////
/////////////////////////////////////////////////

//if (thisBrowserVersion == "NS4") {
//	document.write('<link rel=stylesheet type="text/css" href="/css/netscape.css" title=master>');
//}

//else {
//	document.write('<link rel=stylesheet type="text/css" href="/css/default.css" title=master>');
//}