var agt = navigator.userAgent.toLowerCase();
var versInt = parseInt(navigator.appVersion);
var is_ie	= ((agt.indexOf("msie") != -1) && (agt.indexOf("opera") == -1));
var is_ie3    = (is_ie && (versInt < 4));
var is_ie4    = (is_ie && (versInt == 4) && (agt.indexOf("msie 4")!=-1) );
var is_aol   = (agt.indexOf("aol") != -1);
var is_aol3  = (is_aol && is_ie3);
var is_aol4  = (is_aol && is_ie4);
var is_aol5  = (agt.indexOf("aol 5") != -1);
var is_aol6  = (agt.indexOf("aol 6") != -1);
var is_comp   = (agt.indexOf("compuserve") != -1);
var is_comp2000   = (agt.indexOf("cs") != -1);	 
var is_compie = (is_comp && is_ie);



var theURL = 'pop.html';
var width  = 300;
var height = 250;

function popWindow() {
newWindow =
window.open(theURL,'newWindow','toolbar=no,menubar=no,resizable=no,scrollbars=no,status=no,location=no,width='+width+',height='+height);
}


function MENU_goTo( url ) {
	window.location.href = url;
}


function popup(url) { emailWin=window.open(url,"win",'toolbar=0,location=0,directories=0,status=1,menubar=0,scrollbars=1,resizable=1,width=750,height=650');
self.name = "mainWin"; }


function popup2(url) { emailWin=window.open(url,"win",'toolbar=0,location=0,directories=0,status=1,menubar=0,scrollbars=,resizable=,width=400,height=500');
self.name = "mainWin"; }


function jump2url(){
   jumpUrl=bannerADlink[adNum];
   jumpTarget='_blank';
   if (jumpUrl != ''){
      if (jumpTarget != '')window.open(jumpUrl,jumpTarget);
      else location.href=jumpUrl;
   }
}


function popUp(URL) {
day = new Date();
id = day.getTime();
eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=470,height=325,left = 415,top = 359.5');");
}



function MENU_navBar( tableCellRef, hoverFlag, navStyle ) {
	if ( hoverFlag ) {
		switch ( navStyle ) {
			case 1:
				tableCellRef.style.backgroundColor = '#5b83b4';
				break;
			default:
				if ( document.getElementsByTagName ) {
					tableCellRef.getElementsByTagName( 'a' )[0].style.color = '#5b83b4';
				}
		}
	} else {
		switch ( navStyle ) {
			case 1:
				tableCellRef.style.backgroundColor = '#003399';
				break;
			default:
				if ( document.getElementsByTagName ) {
					tableCellRef.getElementsByTagName( 'a' )[0].style.color = '#003399';
				}
		}
	}
}


function MENU_navBarClick( tableCellRef, navStyle, url ) {
	MENU_navBar( tableCellRef, 0, navStyle );
	MENU_goTo( url );
}


function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);


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];}
}








function setTransition(){
   if (document.all){
      bannerADrotator.filters.revealTrans.Transition=Math.floor(Math.random()*23);
      bannerADrotator.filters.revealTrans.apply();
   }
}


function playTransition(){
   if (document.all)
      bannerADrotator.filters.revealTrans.play()
}


function nextAd(){
   if(adNum<bannerAD.length-1)adNum++ ;
      else adNum=0;
   setTransition();
   document.images.bannerADrotator.src=bannerAD[adNum];
   playTransition();
   theTimer=setTimeout("nextAd()", 5000);
}


function displayStatusMsg() { 
   status=bannerADlink[adNum];
   document.returnValue = true;
}


// BannerAD

   var bannerAD=new Array();
   var bannerADlink=new Array();
   var adNum=0;

   bannerAD[0]="images/specials/frame1.gif";
   bannerADlink[0]="http://www.secure-res.com/emgr/csemail.asp?ID=419";
   bannerAD[1]="images/specials/frame2.gif";
   bannerADlink[1]="http://www.secure-res.com/emgr/csemail.asp?ID=419";
   bannerAD[2]="images/specials/frame3.gif";
   bannerADlink[2]="http://www.secure-res.com/emgr/csemail.asp?ID=419";

   var preloadedimages=new Array();
   for (i=1;i<bannerAD.length;i++){
      preloadedimages[i]=new Image();
      preloadedimages[i].src=bannerAD[i];
   }




{
alt1 = new Image();
alt1.src = "images/menu/ro_disney.jpg";
alt2 = new Image();
alt2.src = "images/menu/ro_ourhotel.jpg";
alt3 = new Image();
alt3.src = "images/menu/ro_reservation.jpg";
alt4 = new Image();
alt4.src = "images/menu/ro_special.gif";
alt5 = new Image();
alt5.src = "images/menu/ro_packages.jpg";
alt6 = new Image();
alt6.src = "images/menu/ro_groups.jpg";
alt7 = new Image();
alt7.src = "images/menu/ro_home.jpg";
alt8 = new Image();
alt8.src = "images/menu/ro_home.jpg";
graphic1= new Image();
graphic1.src = "images/menu/disney_off.gif";
graphic1on = new Image();
graphic1on.src = "images/menu/disney_on.gif";
graphic2= new Image();
graphic2.src = "images/menu/resort_off.gif";
graphic2on = new Image();
graphic2on.src = "images/menu/resort_on.gif";
graphic3= new Image();
graphic3.src = "images/menu/reservations_off.gif";
graphic3on = new Image();
graphic3on.src = "images/menu/reservations_on.gif";
graphic4= new Image();
graphic4.src = "images/menu/specials_off.gif";
graphic4on = new Image();
graphic4on.src = "images/menu/specials_on.gif";
graphic5= new Image();
graphic5.src = "images/menu/packages_off.gif";
graphic5on = new Image();
graphic5on.src = "images/menu/packages_on.gif";
graphic6= new Image();
graphic6.src = "images/menu/groups_off.gif";
graphic6on = new Image();
graphic6on.src = "images/menu/groups_on.gif";
graphic7= new Image();
graphic7.src = "images/menu/videotour_off.gif";
graphic7on = new Image();
graphic7on.src = "images/menu/videotour_on.gif";
graphic8= new Image();
graphic8.src = "images/menu/home_off.gif";
graphic8on = new Image();
graphic8on.src = "images/menu/home_on.gif";
}
function imageChange(imageID,imageName,imageID2,imageName2) {
{
document.images[imageID].src = eval(imageName + ".src");
document.images[imageID2].src = eval(imageName2 + ".src");
}

}


