// Gallery script.
// With image cross fade effect for those browsers that support it.
// Script copyright (C) 2004 www.cryer.co.uk.

var j = 0;
var PictArray = new Array();
var CaptionArray = new Array();

PictArray[0] = "http://www.tremblantski.co.uk/tremblant-ski/images/DiningTableView.jpg";
PictArray[1] = "http://www.tremblantski.co.uk/tremblant-ski/images/AubergeLakeView.jpg";
PictArray[2] = "http://www.tremblantski.co.uk/tremblant-ski/images/FiresideAreaFromDining.jpg";
PictArray[3] = "http://www.tremblantski.co.uk/tremblant-ski/images/MasterBedroom.jpg";
PictArray[4] = "http://www.tremblantski.co.uk/tremblant-ski/images/Den.jpg";
PictArray[5] = "http://www.tremblantski.co.uk/tremblant-ski/images/FiresideAreaFromAbove.jpg";
PictArray[6] = "http://www.tremblantski.co.uk/tremblant-ski/images/Kitchen.jpg";
PictArray[7] = "http://www.tremblantski.co.uk/tremblant-ski/images/Bedroom4.jpg";
PictArray[8] = "http://www.tremblantski.co.uk/tremblant-ski/images/DiningTable.jpg";
PictArray[9] = "http://www.tremblantski.co.uk/tremblant-ski/images/Bedroom2.jpg";
PictArray[10] = "http://www.tremblantski.co.uk/tremblant-ski/images/ExteriorFrontView.jpg";
PictArray[11] = "http://www.tremblantski.co.uk/tremblant-ski/images/LacSuperieur.jpg";
PictArray[12] = "http://www.tremblantski.co.uk/tremblant-ski/images/ExteriorSummer.jpg";
PictArray[13] = "http://www.tremblantski.co.uk/tremblant-ski/images/TennisCourt.jpg";
PictArray[14] = "http://www.tremblantski.co.uk/tremblant-ski/images/OutsideTable.jpg";
PictArray[15] = "http://www.tremblantski.co.uk/tremblant-ski/images/MountainView2.jpg";
PictArray[16] = "http://www.tremblantski.co.uk/tremblant-ski/images/BathroomWetroom.jpg";
PictArray[17] = "http://www.tremblantski.co.uk/tremblant-ski/images/Den2.jpg";
PictArray[18] = "http://www.tremblantski.co.uk/tremblant-ski/images/BalconyView.jpg";
PictArray[19] = "http://www.tremblantski.co.uk/tremblant-ski/images/LakeTremblant.jpg";
PictArray[20] = "http://www.tremblantski.co.uk/tremblant-ski/images/ViewOfMountain.jpg";
PictArray[21] = "http://www.tremblantski.co.uk/tremblant-ski/images/ExteriorLongShot.jpg";
PictArray[22] = "http://www.tremblantski.co.uk/tremblant-ski/images/TremblantFromTheLake.jpg";
PictArray[23] = "http://www.tremblantski.co.uk/tremblant-ski/images/MasterBedroom3.jpg";
PictArray[24] = "http://www.tremblantski.co.uk/tremblant-ski/images/OpenFire.jpg";
PictArray[25] = "http://www.tremblantski.co.uk/tremblant-ski/images/IpodDock.jpg";
PictArray[26] = "http://www.tremblantski.co.uk/tremblant-ski/images/NationalPark2.jpg";
PictArray[27] = "http://www.tremblantski.co.uk/tremblant-ski/images/NationalPark.jpg";
PictArray[28] = "http://www.tremblantski.co.uk/tremblant-ski/images/ViewFromMountainTop.jpg";
PictArray[29] = "http://www.tremblantski.co.uk/tremblant-ski/images/DeerInGrounds.jpg";
PictArray[30] = "http://www.tremblantski.co.uk/tremblant-ski/images/AubergeDuLac.jpg";
PictArray[31] = "http://www.tremblantski.co.uk/tremblant-ski/images/WasherDryer.jpg";
PictArray[32] = "http://www.tremblantski.co.uk/tremblant-ski/images/Den3.jpg";
PictArray[33] = "http://www.tremblantski.co.uk/tremblant-ski/images/Bedroom3.jpg";
PictArray[34] = "http://www.tremblantski.co.uk/tremblant-ski/images/GroundFloorWC.jpg";
PictArray[35] = "http://www.tremblantski.co.uk/tremblant-ski/images/SkiLiftInTheSummer.jpg";
PictArray[36] = "http://www.tremblantski.co.uk/tremblant-ski/images/TwoPlacesToEat.jpg";
PictArray[37] = "http://www.tremblantski.co.uk/tremblant-ski/images/Ensuite2.jpg";
PictArray[38] = "http://www.tremblantski.co.uk/tremblant-ski/images/Bridge.jpg";
PictArray[39] = "http://www.tremblantski.co.uk/tremblant-ski/images/BathroomWetroom2.jpg";
PictArray[40] = "http://www.tremblantski.co.uk/tremblant-ski/images/TremblantVillage.jpg";
PictArray[41] = "http://www.tremblantski.co.uk/tremblant-ski/images/PoolAndSpa.jpg";
PictArray[42] = "http://www.tremblantski.co.uk/tremblant-ski/images/River.jpg";
PictArray[43] = "http://www.tremblantski.co.uk/tremblant-ski/images/Path.jpg";
PictArray[44] = "http://www.tremblantski.co.uk/tremblant-ski/images/ViewingPlatform.jpg";
PictArray[45] = "http://www.tremblantski.co.uk/tremblant-ski/images/LakeView.jpg";
PictArray[46] = "http://www.tremblantski.co.uk/tremblant-ski/images/InformationBoard.jpg";
PictArray[47] = "http://www.tremblantski.co.uk/tremblant-ski/images/HighLakeView.jpg";
PictArray[48] = "http://www.tremblantski.co.uk/tremblant-ski/images/AerialView.jpg";
PictArray[49] = "http://www.tremblantski.co.uk/tremblant-ski/images/InsideTheAubergeDuLac.jpg";
PictArray[50] = "http://www.tremblantski.co.uk/tremblant-ski/images/LaBouleRiver.jpg";
PictArray[51] = "http://www.tremblantski.co.uk/tremblant-ski/images/WinterLakeView.jpg";
PictArray[52] = "http://www.tremblantski.co.uk/tremblant-ski/images/Snow.jpg";
PictArray[52] = "http://www.tremblantski.co.uk/tremblant-ski/images/WoodenWalls.jpg";
PictArray[53] = "http://www.tremblantski.co.uk/tremblant-ski/images/Staircase.jpg";


CaptionArray[-4] = "Please Click Next >>";
CaptionArray[-3] = "Please Click Next >>";
CaptionArray[-2] = "Please Click Next >>";
CaptionArray[-1] = "Please Click Next >>";
CaptionArray[0] = "Dining Table";
CaptionArray[1] = "Auberge Lake View";
CaptionArray[2] = "Fireside Area";
CaptionArray[3] = "Master Bedroom";
CaptionArray[4] = "Den";
CaptionArray[5] = "Fireside Area";
CaptionArray[6] = "Kitchen";
CaptionArray[7] = "Bedroom 4";
CaptionArray[8] = "Dining Table";
CaptionArray[9] = "Bedroom 2";
CaptionArray[10] = "Exterior View";
CaptionArray[11] = "Lac Superieur";
CaptionArray[12] = "Exterior Summer";
CaptionArray[13] = "Tennis Court";
CaptionArray[14] = "Outside Table";
CaptionArray[15] = "Mountain View";
CaptionArray[16] = "Bathroom Wetroom";
CaptionArray[17] = "Den";
CaptionArray[18] = "Balcony View";
CaptionArray[19] = "Lake Tremblant";
CaptionArray[20] = "View Of Mountain";
CaptionArray[21] = "Exterior Long Shot";
CaptionArray[22] = "Mont Tremblant";
CaptionArray[23] = "Master Bedroom";
CaptionArray[24] = "Open Fire";
CaptionArray[25] = "Ipod Dock";
CaptionArray[26] = "National Park";
CaptionArray[27] = "National Park";
CaptionArray[28] = "View From Mountain Top";
CaptionArray[29] = "Deer In Grounds";
CaptionArray[30] = "Auberge Du Lac";
CaptionArray[31] = "Washer Dryer";
CaptionArray[32] = "Den";
CaptionArray[33] = "Bedroom 3";
CaptionArray[34] = "Ground Floor WC";
CaptionArray[35] = "Ski Lift In The Summer";
CaptionArray[36] = "Two Places To Eat";
CaptionArray[37] = "Ensuite";
CaptionArray[38] = "Bridge";
CaptionArray[39] = "Bathroom Wetroom";
CaptionArray[40] = "Tremblant Village";
CaptionArray[41] = "Pool And Spa";
CaptionArray[42] = "River";
CaptionArray[43] = "Path";
CaptionArray[44] = "Viewing Platform";
CaptionArray[45] = "Lake View";
CaptionArray[46] = "Information Board";
CaptionArray[47] = "High Lake View";
CaptionArray[48] = "Aerial View";
CaptionArray[49] = "Inside The Auberge Du Lac";
CaptionArray[50] = "La Boule River";
CaptionArray[51] = "Winter Lake View";
CaptionArray[52] = "Snow";
CaptionArray[52] = "Wooden Walls";
CaptionArray[53] = "Staircase";
CaptionArray[54] = "Please click << Previous";
CaptionArray[55] = "Please click << Previous";
CaptionArray[56] = "Please click << Previous";




function LoadGallery(pictureName,int,titleCaption,int)
{
  
var picture = document.getElementById(pictureName);

if (picture.filters)
  {
    picture.title = CaptionArray[int];
    picture.alt = CaptionArray[int];
    picture.name = CaptionArray[int];


    picture.style.filter="blendTrans(duration=1)";
    picture.filters.blendTrans.Apply();
  }
    picture.src = PictArray[int];
    picture.title = CaptionArray[int];
    picture.alt = CaptionArray[int];
    picture.name = CaptionArray[int];


  if (picture.filters)
  { 
    picture.title = CaptionArray[int];
    picture.alt = CaptionArray[int];
    picture.name = CaptionArray[int];


  picture.filters.blendTrans.Play();
  }
  

    picture.title = CaptionArray[int];
    picture.alt = CaptionArray[int];
    picture.name = CaptionArray[int];

    document.getElementById(titleCaption).innerHTML=CaptionArray[int];


}




function shortPopUp( url, name, width, height, scrollbars )

{ var top = "50"; var left = "50"; 

if( scrollbars == null ) scrollbars = "0"; str = ""; str += "resizable=1,titlebar=0,menubar=0,"; 
str += "toolbar=0,location=0,directories=0,status=0,"; 
str += "scrollbars=" + scrollbars + ","; str += "width=" + width + ","; str += "height=" + height + ","; 
str += "top=" + top + ","; str += "left=" + left;
 window.open( url, name, str );
}



function echeck(str) {

		var at="@"
		var dot="."
		var lat=str.indexOf(at)
		var lstr=str.length
		var ldot=str.indexOf(dot)
		if (str.indexOf(at)==-1){
		   alert("Please enter a valid E-mail Address to get a Quick Quote")
		   return false
		}

		if (str.indexOf(at)==-1 || str.indexOf(at)==0 || str.indexOf(at)==lstr){
		   alert("Please enter a valid E-mail Address to get a Quick Quote")
		   return false
		}

		if (str.indexOf(dot)==-1 || str.indexOf(dot)==0 || str.indexOf(dot)==lstr){
		    alert("Please enter a valid E-mail Address to get a Quick Quote")
		    return false
		}

		 if (str.indexOf(at,(lat+1))!=-1){
		    alert("Please enter a valid E-mail Address to get a Quick Quote")
		    return false
		 }

		 if (str.substring(lat-1,lat)==dot || str.substring(lat+1,lat+2)==dot){
		    alert("Please enter a valid E-mail Address to get a Quick Quote")
		    return false
		 }

		 if (str.indexOf(dot,(lat+2))==-1){
		    alert("Please enter a valid E-mail Address to get a Quick Quote")
		    return false
		 }
		
		 if (str.indexOf(" ")!=-1){
		    alert("Please enter a valid E-mail Address to get a Quick Quote")
		    return false
		 }

 		 return true					
	}

function ValidateForm(){
	var emailID=document.input.emailaddress
	
	if ((emailID.value==null)||(emailID.value=="")){
		alert("Please enter a valid E-mail Address to get a Quick Quote")
		emailID.focus()
		return false
	}
	if (echeck(emailID.value)==false){
		emailID.value=""
		emailID.focus()
		return false
	}
	return true
 }



// ************************************************************************************


var i = 0;
var myArray = new Array();

myArray[-2] = "<BR><BR><BR><BR><BR><BR>Please Click Next >>";
myArray[-1] = "<BR><BR><BR><BR><BR><BR>Please Click Next >>";
myArray[0] = "<BR><BR><BR><BR><BR><BR>Please Click Next >>";
myArray[1] = "<BR>Access to private beach with hotel facilities<BR><BR>Walking distance from the National Park<BR><BR>On lake and river<BR><BR>In One Acre of Land<BR><BR>Complimentary Wi-Fi";
myArray[2] = "<BR>4 bedrooms<BR><BR>3.5 bathrooms with ensuite and wet room<BR><BR>Twin sinks<BR><BR>Seperate Den Area<BR><BR>Real fire place with logs supplied";
myArray[3] = "<BR>Large furnished balcony with barbecue grill and forest views<BR><BR>Full kitchen and open-plan living/dining areas<BR><BR>Oversized natural-stone wood-burning fireplace<BR><BR>Flat screen high-def TV with satellite channels and a DVD player";
myArray[4] = "<BR>DVD Player<BR><BR>Pay movies and CD player<BR><BR>Top End Ipod Dock<BR><BR>Hypo-allergenic bedding available<BR><BR>Premium bedding <BR>";
myArray[5] = "<BR>Separate sitting area<BR><BR>Patio<BR><BR>Balcony<BR><BR>Climate control<BR><BR>Direct-dial phone";
myArray[6] = "<BR>Telephone with free local calls<BR><BR>Refrigerator<BR><BR>Coffee/tea maker<BR><BR>Microwave<BR><BR>Housekeeping and Turndown service (on request)";
myArray[7] = "<BR>Hair dryer<BR><BR>Bathroom scales<BR><BR>Shower/tub combination<BR><BR>Separate bathtub and shower<BR><BR>Makeup mirrors";
myArray[8] = "<BR>Massage available in room<BR><BR>Iron and ironing board<BR><BR>Television<BR><BR>Desk<BR><BR>Drying Area";
myArray[9] = "<BR>Clock radio<BR><BR>Windows open<BR><BR>Welcome amenities<BR><BR>Cribs (infant beds) available<BR><BR>Cookware/dishes/utensils";
myArray[10] = "<BR>Washer dryer<BR><BR>Television Satellite service<BR><BR>Separate dining area<BR><BR>Cordless phone<BR><BR>Dishwasher";
myArray[11] = "<BR><BR><BR><BR><BR><BR>Please Click << Previous";
myArray[12] = "<BR><BR><BR><BR><BR><BR>Please Click << Previous";
myArray[13] = "<BR><BR><BR><BR><BR><BR>Please Click << Previous";



function changeTextUp(){

document.getElementById('guestbook').innerHTML =  myArray[i+1];

i+=1;

}


function changeTextDown(){	

document.getElementById('guestbook').innerHTML = myArray[i-1];
	
i-=1;

  
}

 
/***********************************************
* Drop Down Date select script- by JavaScriptKit.com
* This notice MUST stay intact for use
* Visit JavaScript Kit at http://www.javascriptkit.com/ for this script and more
***********************************************/
 
var daytext= ['1','2','3','4','5','6','7','8','9','10','11','12','13','14','15','16','17','18','19','20','21','22','23','24','25','26','27','28','29','30','31'];
var monthtext=['January','February','March','April','May','June','July','August','September','October','November','December'];
 
function populatedropdown(dayfield, monthfield, yearfield){
var today=new Date()
var dayfield=document.getElementById(dayfield)
var monthfield=document.getElementById(monthfield)
var yearfield=document.getElementById(yearfield)


for (var i=0; i<31; i++)

dayfield.options[i]=new Option(daytext[i], daytext[i])
dayfield.options[today.getDate()]=new Option(daytext[today.getDate()], daytext[today.getDate()], true, true) //select today's day


for (var m=0; m<12; m++)
monthfield.options[m]=new Option(monthtext[m], monthtext[m])
monthfield.options[today.getMonth()]=new Option(monthtext[today.getMonth()], monthtext[today.getMonth()], true, true) //select today's month
var thisyear=today.getFullYear()
for (var y=0; y<5; y++){
yearfield.options[y]=new Option(thisyear, thisyear)
thisyear+=1
}
yearfield.options[0]=new Option(today.getFullYear(), today.getFullYear(), true, true) //select today's year
}
 