function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}
function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}




var hpwindowname;

function SendMe(){
//alert ("")
if(hpwindowname){
if(!hpwindowname.closed) hpwindowname.close();
}
hpwindowname = window.open("send_a_friend.asp","hpwindowname","width=346, height=455,scrollbars=0,location=0,status=0,resizable=0,menubar=0,toolbars=0");
hpwindowname.focus();

}

function pop_me(){
//alert ("")
if(hpwindowname){
if(!hpwindowname.closed) hpwindowname.close();
}
hpwindowname = window.open("ajs_news.asp","hpwindowname","width=346, height=200,scrollbars=0,location=0,status=0,resizable=0,menubar=0,toolbars=0");
hpwindowname.focus();

}
function serachPop_Me(){
//alert ("")
if(hpwindowname){
if(!hpwindowname.closed) hpwindowname.close();
}
hpwindowname = window.open("../ajs_news.asp","hpwindowname","width=346, height=200,scrollbars=0,location=0,status=0,resizable=0,menubar=0,toolbars=0");
hpwindowname.focus();

}

function swapStyle0(theHref) {
	var sOption="toolbar=0,location=no,directories=0,menubar=no,scrollbars=yes,width=760"; 
	var  sPageText2 = document.getElementById('main').innerHTML;

	var  sTitle=document.title;
	var  sUrl=document.location;
	var winprint=window.open("","",sOption); 
	winprint.document.open(); 
	winprint.document.write("<html><head><link rel=\"stylesheet\" type=\"text/css\" href=\"print.css\" ><title>"+sTitle+"</title></head><body>"); 
	winprint.document.write("<center><table width=\"750\" cellspacing=\"0\" cellpadding=\"0\" border=\"0\"><tr><td valign=\"top\"><table cellspacing=\"0\" cellpadding=\"0\" border=\"0\"  >");
	winprint.document.write("<tr><td  background=\"images/print_header.gif\" width=750 height=77><div style=\"padding-left:400px;\">");
	winprint.document.write("<div class=\"titlefont\">");
	winprint.document.write(sTitle);
		winprint.document.write("</div></div></td></tr></table>");
	

	winprint.document.write("<table cellspacing=\"0\" cellpadding=\"0\" border=\"0\" width=\"750\" ><tr><td align=\"left\" valign=\"top\" style=\"padding-left:20px;padding-right:20px;\" ><br><br>");
	winprint.document.write("<br><br><div align=\"right\"><a href=\"javascript:window.print();\">Print</a>&nbsp;|&nbsp;<a href=\"javascript:window.close();\">Close</a></div>");
	winprint.document.write(sPageText2);
	winprint.document.write("</td></tr>");
	winprint.document.write("</table><table width=\"750\"><tr><td align=\"center\" valign=\"top\" >");
	winprint.document.write("</strong></font><br><font size=1><center><!--ph: 877-442-4820&nbsp;|&nbsp;e: <a href=\"mailto:info@iia.edu\">info@iia.edu</a>&nbsp;|&nbsp;w: www.iia.edu<br>-->");
	winprint.document.write("&copy;2008 AJ's Fine Foods. All rights reserved</center></font>");
	//winprint.document.write("<BR><strong><font size=1>Prined from: "); 
	//winprint.document.write(sUrl)
	winprint.document.write("</td></tr></table>");
	winprint.document.write("</body></html>"); 
	
	winprint.document.close(); 
	winprint.focus(); 
	return false; //cancels link action
}

function recipe_pop_me(url){
	if(hpwindowname){
	if(!hpwindowname.closed) hpwindowname.close();
	}
	hpwindowname = window.open(url,"hpwindowname","width=600, height=600,scrollbars=yes,location=0,status=0,resizable=yes,menubar=0,toolbars=0");
	hpwindowname.focus();

}
function print_pop_me(url){
	if(hpwindowname){
	if(!hpwindowname.closed) hpwindowname.close();
	}
	hpwindowname = window.open(url,"hpwindowname","width=600, height=600,scrollbars=yes,location=0,status=0,resizable=yes,menubar=0,toolbars=0");
	hpwindowname.focus();
}
function cake_pop_me(image){
	thisImage = image+".jpg";
	myWindow = window.open("","imagewindow",'width=346,height=448,left = 467,top = 288');
	myWindow.document.write("<title>"+image+"</title>");
	myWindow.document.write("<body onClick='self.close()' topmargin='0' leftmargin='0' marginheight='0' marginwidth='0' style='cursor: pointer;'>");
	myWindow.document.write("<img src=\"images/"+thisImage+"\">");
	myWindow.document.close();	
}
function about_pop_me(image){
	thisImage = image+".jpg";
	myWindow = window.open("","imagewindow",'width=306,height=204,left = 467,top = 288');
	myWindow.document.write("<title>"+image+"</title>");
	myWindow.document.write("<body onClick='self.close()' topmargin='0' leftmargin='0' marginheight='0' marginwidth='0' style='cursor: pointer;'>");
	myWindow.document.write("<img src=\"images/"+thisImage+"\">");
	myWindow.document.close();	
}

function popUp(image) {
thisImage ="images/" + image + ".jpg";
day = new Date();
id = day.getTime();
eval("page" + id + " = window.open(thisImage, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=346,height=448,left = 467,top = 288');");
}