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];}
}
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 mmLoadMenus() {
  if (window.mm_menu_0115114539_0) return;
        window.mm_menu_0115114539_0 = new Menu("root",184,22,"Arial, Helvetica, sans-serif",12,"#000073","#ffffff","#cccccc","#000073","left","middle",5,0,500,-5,7,true,true,true,0,true,true);
  mm_menu_0115114539_0.addMenuItem("Trip&nbsp;Planning&nbsp;Overview","location='../trip_planning.htm'");
  mm_menu_0115114539_0.addMenuItem("Make&nbsp;Nanaimo&nbsp;Your&nbsp;Hub","location='../local.htm#Hub'");
  mm_menu_0115114539_0.addMenuItem("Nanaimo&nbsp;History","location='../local/history_of_nanaimo.htm'");
  mm_menu_0115114539_0.addMenuItem("What&nbsp;To&nbsp;Do","location='../local/history_of_nanaimo.htm#todo'");
  mm_menu_0115114539_0.addMenuItem("Day&nbsp;Tours&nbsp;South","location='../local/day_tours_s.htm'");
  mm_menu_0115114539_0.addMenuItem("Day&nbsp;Tours&nbsp;North","location='../local/day_tours_n.htm'");
  mm_menu_0115114539_0.addMenuItem("Island&nbsp;Restaurants","location='../local/restaurants_pubs.htm'");
  mm_menu_0115114539_0.addMenuItem("Directions&nbsp;and&nbsp;Maps","location='../directions.htm'");
  mm_menu_0115114539_0.addMenuItem("Moving&nbsp;To&nbsp;Nanaimo","location='../moving_nanaimo.htm'");
  mm_menu_0115114539_0.addMenuItem("Car&nbsp;Rentals","location='../car_rentals.htm'");
  mm_menu_0115114539_0.addMenuItem("B.C.&nbsp;Ferries","location='../bc_ferries.htm'");
   mm_menu_0115114539_0.hideOnMouseOut=true;
   mm_menu_0115114539_0.bgColor='#000033';
   mm_menu_0115114539_0.menuBorder=1;
   mm_menu_0115114539_0.menuLiteBgColor='#000033';
   mm_menu_0115114539_0.menuBorderBgColor='#CCCCCC';
    window.mm_menu_0115114403_1 = new Menu("root",347,22,"Arial, Helvetica, sans-serif",12,"#000073","#ffffff","#cccccc","#000073","left","middle",5,0,500,-5,7,true,true,true,0,true,true);
  mm_menu_0115114403_1.addMenuItem("Deluxe&nbsp;Channelview&nbsp;Fireplace&nbsp;Suite","location='../lodging.htm#1'");
  mm_menu_0115114403_1.addMenuItem("Deluxe&nbsp;Channelview&nbsp;King&nbsp;Kitchen&nbsp;Suite","location='../lodging.htm#2'");
  mm_menu_0115114403_1.addMenuItem("One&nbsp;Bedroom&nbsp;Kitchen&nbsp;Suite","location='../lodging.htm#3'");
  mm_menu_0115114403_1.addMenuItem("Patio&nbsp;Studio","location='../lodging.htm#4'");
  mm_menu_0115114403_1.addMenuItem("Cozy&nbsp;Studio","location='../lodging.htm#5'");
  mm_menu_0115114403_1.addMenuItem("Business&nbsp;Travelers","location='../business_travelers.htm'");
  mm_menu_0115114403_1.addMenuItem("Extended&nbsp;Stays","location='../extended.htm'");
  mm_menu_0115114403_1.addMenuItem("Moving&nbsp;To&nbsp;Nanaimo","location='../moving_nanaimo.htm'");
  mm_menu_0115114403_1.addMenuItem("Canada&nbsp;Select&nbsp;Rating","location='../canada_select.htm'");
  mm_menu_0115114403_1.addMenuItem("Testimonials","location='../testimonials.htm'");
   mm_menu_0115114403_1.hideOnMouseOut=true;
   mm_menu_0115114403_1.bgColor='#000033';
   mm_menu_0115114403_1.menuBorder=1;
   mm_menu_0115114403_1.menuLiteBgColor='#000033';
   mm_menu_0115114403_1.menuBorderBgColor='#CCCCCC';
window.mm_menu_0115114604_2 = new Menu("root",138,22,"Arial, Helvetica, sans-serif",12,"#000073","#ffffff","#cccccc","#000073","left","middle",5,0,500,-5,7,true,true,true,0,true,true);
  mm_menu_0115114604_2.addMenuItem("A&nbsp;&&nbsp;W&nbsp;Restaurant","location='../coupons/coupon.htm#1'");
   mm_menu_0115114604_2.hideOnMouseOut=true;
   mm_menu_0115114604_2.bgColor='#000033';
   mm_menu_0115114604_2.menuBorder=1;
   mm_menu_0115114604_2.menuLiteBgColor='#000033';
   mm_menu_0115114604_2.menuBorderBgColor='#CCCCCC';
window.mm_menu_0115114504_3 = new Menu("root",168,22,"Arial, Helvetica, sans-serif",12,"#000073","#ffffff","#cccccc","#000073","left","middle",5,0,500,-5,7,true,true,true,0,true,true);
  mm_menu_0115114504_3.addMenuItem("About&nbsp;Our&nbsp;Adventures","location='../adventures.htm'");
  mm_menu_0115114504_3.addMenuItem("Diving&nbsp;Nanaimo","location='http://www.divingbc.com/'");
  mm_menu_0115114504_3.addMenuItem("Snorkeling&nbsp;With&nbsp;Seals","location='http://www.divingbc.com/snorkel_package.htm'");
  mm_menu_0115114504_3.addMenuItem("West&nbsp;Coast&nbsp;Explorer","location='../adventures/parks.htm'");
  mm_menu_0115114504_3.addMenuItem("Heritage&nbsp;Walking&nbsp;Tours","location='../adventures/heritage.htm'");
  mm_menu_0115114504_3.addMenuItem("Fishing","location='../adventures/fishing.htm'");
  mm_menu_0115114504_3.addMenuItem("Kayaking","location='../adventures/kayaking.htm'");
  mm_menu_0115114504_3.addMenuItem("Hiking","location='../adventures/hiking.htm'");
  mm_menu_0115114504_3.addMenuItem("Biking","location='../adventures/biking.htm'");
  mm_menu_0115114504_3.addMenuItem("West&nbsp;Coast&nbsp;Trail","location='../adventures/trail.htm'");
   mm_menu_0115114504_3.hideOnMouseOut=true;
   mm_menu_0115114504_3.bgColor='#000033';
   mm_menu_0115114504_3.menuBorder=1;
   mm_menu_0115114504_3.menuLiteBgColor='#000033';
   mm_menu_0115114504_3.menuBorderBgColor='#CCCCCC';
  window.mm_menu_0115114656_4 = new Menu("root",101,22,"Arial, Helvetica, sans-serif",12,"#000073","#ffffff","#cccccc","#000073","left","middle",5,0,500,-5,7,true,true,true,0,true,true);
  mm_menu_0115114656_4.addMenuItem("Rates","location='../rates.htm'");
  mm_menu_0115114656_4.addMenuItem("Enquiries","location='../reservations.htm'");
  mm_menu_0115114656_4.addMenuItem("Reservations","location='../reservations.htm'");
   mm_menu_0115114656_4.hideOnMouseOut=true;
   mm_menu_0115114656_4.bgColor='#000033';
   mm_menu_0115114656_4.menuBorder=1;
   mm_menu_0115114656_4.menuLiteBgColor='#000033';
   mm_menu_0115114656_4.menuBorderBgColor='#CCCCCC';

mm_menu_0115114656_4.writeMenus();
} // mmLoadMenus()


function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}

function MM_showMenu(menu, x, y, child, imgname) {
	if (!window.mmWroteMenu) return;
	MM_clearTimeout();
	if (menu) {
		var obj = FIND(imgname) || document.images[imgname] || document.links[imgname] || document.anchors[imgname];
		x = moveXbySlicePos (x, obj);
		y = moveYbySlicePos (y, obj);
	}
	if (document.layers) {
		if (menu) {
			var l = menu.menuLayer || menu;
			l.top = l.left = 1;
			hideActiveMenus();
			if (this.visibility) l = this;
			window.ActiveMenu = l;
		} else {
			var l = child;
		}
		if (!l) return;
		for (var i=0; i<l.layers.length; i++) { 			   
			if (!l.layers[i].isHilite) l.layers[i].visibility = "inherit";
			if (l.layers[i].document.layers.length > 0) MM_showMenu(null, "relative", "relative", l.layers[i]);
		}
		if (l.parentLayer) {
			if (x != "relative") l.parentLayer.left = x || window.pageX || 0;
			if (l.parentLayer.left + l.clip.width > window.innerWidth) l.parentLayer.left -= (l.parentLayer.left + l.clip.width - window.innerWidth);
			if (y != "relative") l.parentLayer.top = y || window.pageY || 0;
			if (l.parentLayer.isContainer) {
				l.Menu.xOffset = window.pageXOffset;
				l.Menu.yOffset = window.pageYOffset;
				l.parentLayer.clip.width = window.ActiveMenu.clip.width +2;
				l.parentLayer.clip.height = window.ActiveMenu.clip.height +2;
				if (l.parentLayer.menuContainerBgColor && l.Menu.menuBgOpaque ) l.parentLayer.document.bgColor = l.parentLayer.menuContainerBgColor;
			}
		}
		l.visibility = "inherit";
		if (l.Menu) l.Menu.container.visibility = "inherit";
	} else if (FIND("menuItem0")) {
		var l = menu.menuLayer || menu;	
		hideActiveMenus();
		if (typeof(l) == "string") l = FIND(l);
		window.ActiveMenu = l;
		var s = l.style;
		s.visibility = "inherit";
		if (x != "relative") {
			s.pixelLeft = x || (window.pageX + document.body.scrollLeft) || 0;
			s.left = s.pixelLeft + 'px';
		}
		if (y != "relative") {
			s.pixelTop = y || (window.pageY + document.body.scrollTop) || 0;
			s.top = s.pixelTop + 'px';
		}
		l.Menu.xOffset = document.body.scrollLeft;
		l.Menu.yOffset = document.body.scrollTop;
	}
	if (menu) window.activeMenus[window.activeMenus.length] = l;
	MM_clearTimeout();
}
