var addthis_pub="jumpingtrout";

function reservation_pop(company_id){
	var reservationwin=dhtmlmodal.open("reservationbox", "iframe", "reservations_pop.asp?company_id=" + company_id , "Online Reservations", "width=475px,height=380px,resize=0,scrolling=0,center=1", "recal");
	reservationwin.onclose=function(){return true;}
}

function events_pop(id,im,iy){
	showdate = id + "/" + im + "/" + iy;
	urldate = id + "." + im + "." + iy;
	var eventswin=dhtmlmodal.open("eventsbox", "iframe", "events_pop.asp?edate=" + urldate , "Current Events " + showdate, "width=475px,height=380px,resize=0,scrolling=0,center=1", "recal");
	eventswin.onclose=function(){return true;}
}

function show_event(event_id){
	var eventswin=dhtmlmodal.open("eventsbox", "iframe", "events_pop.asp?event_id=" + event_id , "Event Detail" , "width=475px,height=380px,resize=0,scrolling=0,center=1", "recal");
	eventswin.onclose=function(){return true;}
}

function review_pop(company_id){
	var reviewwin=dhtmlmodal.open("reviewbox", "iframe", "/reviews/default.asp?company_id=" + company_id , "Write A Review", "width=525px,height=500px,resize=0,scrolling=0,center=1", "recal");
	reviewwin.onclose=function(){return true;}
}

function Print_Coupons(company_id){window.open("http://www.rockfordsearch.com/print_coupons.asp?domain_id="+domain_id+"&Company_ID=" + company_id,"popPrint_" + company_id,"width=800,height=450,left=0,top=0,scrollbars");}
function PrintCouponsEvents(company_id){Print_Coupons(company_id);}

sub_nav_ids = new Array("azname_sub","cuisine_sub");

function handlediv(divid){
	cur_status = document.getElementById(divid).style.display;
	if(cur_status == "" || cur_status == "none"){
		hideallsubs();
		document.getElementById(divid).style.display="block";
	}
	else{
		document.getElementById(divid).style.display="none";
	}
}

function hideallsubs(){
	for(X=0;X<eval(sub_nav_ids).length;X++){
		document.getElementById(sub_nav_ids[X]).style.display="none";
	}
}

function showaz(){handlediv("azname_sub");}
function showctypes(){handlediv("cuisine_sub");}
function shownetwork(){handlediv("network_sub");}
function parent_url(iurl){parent.location.href=iurl;}
