
		/** Code & functions for changing the text on the home page **/
		
/** Keeps track of the current page number **/
var home_pageNo = 1; 
var location_pageNo = 1;
var aboutus_pageNo = 1;

/** Declare and init arrays to hold the text for the pages **/ 
var home_pages = new Array();
home_pages[1] = "Bar Enal actually means 'Esercisio Nazionali Assistenza (ai) Laboratori' or something similar. Weird? Well, not really, it's a sort of nationalised working men's club where the 'labourer' can go to get a cheap glass of wine/beer/coffee when he's finished work, and sit and read the paper, play cards with friends, argue (typical Italian pastime)and generally relax.  These days it's not really subsidised so much by local government (althoughit actually belongs to the local Comune/Council) any more although the principle of being a 'working men's club' still stands and we actually have quite a large membership of local town folk who come in and...";
home_pages[2] = "play cards during the winter months when their hotels bars shopsand restaurants are closed.  The membership fee goes to a 'committee' just like in English clubs and is used for general maintenance of the place whenever needed. We were actually members of the club for quite a good few years before we took over the tenancy of the place. It was a bit of a mess when we took it over but with patience, a lot of investment and a good supplier, T&C Trento, part of the Carlsberg Italia group, we've gradually turned it into something resembling an English bar/club whilst still remaining acceptable to our Italian members, who, incidentally, are not at all easy to please.";
home_pages[3] = "We're open to non members of course, otherwise we'd see very few people in the summer as most of our local members are business owners.  We have Sky TV too, in fact we can receive over 4,000 TV channels and transmit almost any media onto our 3.5 mtr video screen. Films, DVD, VHS etc. This is a great attraction especially when we can show sporting events such as the UK FA cup final and the World Cup, the World Snooker Championships, Rugby and of course Cricket. We don’t put Golf on though. We'd rather sit through re-runs of Crossroads……  To date, June 2006, we’ve been here for 5.5 years. We’re hoping to make it for a few more yet.";

var location_pages = new Array();
location_pages[1] = "Malcesine is situated on the eastern shores of lake Garda, about 3/4 of the way up. Lake Garda is the largest of Italys lakes being 31 miles long and 11 miles wide at the southern end. Malcesine is one of the oldest towns on the lake and was one of the earliest fishing settlements, dating from circa 357BC. The old original name of the town in the local dialect was 'Mannes selices' which translates colloquially to 'The town under the big bad rock'. The 'Bad rock' being the large limestone promontory where the castle stands. The town originally had its own currency which was recognised and accepted by the Romans who dominated from about AD200 and built the old town walls, parts of which still remain.";
location_pages[2] = "Malcesine’s castle dates from Roman times, the outer part being built as a fortress in the early 3rd century. The outer walls with the squared battlements are the original Roman ramparts. The inner keep was built much later in the 12th century by the “Della Scalas”, the Veronese feudal barons who ruled from the 11th until the late 14th centuries. The central tower is Venetian,  built in the 15th century. Malcesine is protected from bad weather by the Baldo mountains to the east and is kept warm in the winter by the lake which is so deep (1185ft at Casteletto) that it retains an average temperature of 4 degrees centigrade.  Even in the summer!";
location_pages[3] = "In August it sometimes reaches the high teens at the surface, but not often, and in winter it helps to prevent frost and ice from forming. We seldom get any snow, maybe once every five or six years. This year, in January 2006 it snowed for one day only and then melted away again, just like that!. Good job we had the camera handy!";

var aboutus_pages = new Array();
aboutus_pages[1] = "Jeanie comes from Copenhagen Denmark, that’s about all I’m allowed to tell you without getting nagged. She is a mine of information, a brainiac, and speaks goodness knows how many languages having worked all over Europe in the past as a rep and tour guide. She was working here in Malcesine when I arrived 16 years ago with some holiday guests. Her life has never been the same since.";
aboutus_pages[2] = "About me? Aha! I’ll not go on for ages. I’m an ex this and ex that, chef butcher coach truck and bus driver, disc jockey, compère and presenter, stand up comic, publican, milkman, window cleaner, wrestler and driving instructor who just happens to be passionate about life, beer, old cars(I am the magazine editor for the 6/80 & MO Club) and making guitars, oh, and blues music too. I came to the lake for the first time in 1990 and was captured by the above nutcase. In 1991 I came here to work and although it wasn’t planned this way, I’m still here…. Bob.";


/** Declare and init array to hold the path to the images **/
var location_images = new Array();
location_images[1] = "graphics/photos/malcesine.jpg";
location_images[2] = "graphics/photos/castle.jpg";
location_images[3] = "graphics/photos/piazza.jpg";

var aboutus_images = new Array();
aboutus_images[1] = "graphics/photos/jeanie1.jpg";
aboutus_images[2] = "graphics/photos/bob1.jpg";


function home_nextPage() {
  /** Make sure the we are not already on the last page **/
  if(home_pageNo < 3) {
	  /** Retreive a reference to the node
		    Remove it, create a new node based on the
				next next page, then add it to the node **/
	  var node = document.getElementById("text");
	  node.removeChild(node.firstChild);
		var newTextNode = document.createTextNode(home_pages[home_pageNo+1]);
		node.appendChild(newTextNode);
		/** Highlight the correct number of the page index **/		
		switch(home_pageNo) {
			case 1: 
				  document.getElementById("i1").style.color = "#D0790F";
				  document.getElementById("i2").style.color = "white";
					home_pageNo++;
					break;
			case 2:   
				  document.getElementById("i2").style.color = "#D0790F";
				  document.getElementById("i3").style.color = "white";
					home_pageNo++;
					break;
			case 3: break;
			    /** Don't increase the page number because we are already
					    on the last page. **/
		}
	}
}

function home_previousPage() { 
   /** Make sure the we are not on the first page **/ 
	 if(home_pageNo > 1) {
	   var node = document.getElementById("text");
	   node.removeChild(node.firstChild);	
		 var newTextNode = document.createTextNode(home_pages[home_pageNo-1]);
		 node.appendChild(newTextNode);
		 switch(home_pageNo) {
			 case 1: break;

			 case 2: document.getElementById("i2").style.color = "#D0790F";
				  document.getElementById("i1").style.color = "white";
					home_pageNo--;
					break;

			 case 3: document.getElementById("i3").style.color = "#D0790F";
				  document.getElementById("i2").style.color = "white";
					home_pageNo--;
					break;
		 }		 
	}
}


function location_nextPage() {
  /** Make sure the we are not already on the last page **/
  if(location_pageNo < 3) {
	  /** Retreive a reference to the node
		    Remove it, create a new node based on the
				next next page, then add it to the node **/
	  var node = document.getElementById("text");
	  node.removeChild(node.firstChild);
		var newTextNode = document.createTextNode(location_pages[location_pageNo+1]);
		node.appendChild(newTextNode);
		/** Highlight the correct number of the page index **/		
		switch(location_pageNo) {
			case 1: 
				  document.getElementById("i1").style.color = "#D0790F";
				  document.getElementById("i2").style.color = "white";
					location_pageNo++;
					document.getElementById("topphoto").src = location_images[location_pageNo];
					break;
			case 2:   
				  document.getElementById("i2").style.color = "#D0790F";
				  document.getElementById("i3").style.color = "white";
					location_pageNo++;
					document.getElementById("topphoto").src = location_images[location_pageNo];
					break;
			case 3: break;
			    /** Don't increase the page number because we are already
					    on the last page. **/
		}
	}
}

function location_previousPage() { 
   /** Make sure the we are not on the first page **/ 
	 if(location_pageNo > 1) {
	   var node = document.getElementById("text");
	   node.removeChild(node.firstChild);	
		 var newTextNode = document.createTextNode(location_pages[location_pageNo-1]);
		 node.appendChild(newTextNode);
		 switch(location_pageNo) {
			 case 1: break;

			 case 2: document.getElementById("i2").style.color = "#D0790F";
				  document.getElementById("i1").style.color = "white";
					location_pageNo--;
					document.getElementById("topphoto").src = location_images[location_pageNo];
					break;

			 case 3: document.getElementById("i3").style.color = "#D0790F";
				  document.getElementById("i2").style.color = "white";
					location_pageNo--;
					document.getElementById("topphoto").src = location_images[location_pageNo];
					break;
		 }		 
	}
}


function aboutus_nextPage() {
  /** Make sure the we are not already on the last page **/
  if(aboutus_pageNo < 2) {
	  /** Retreive a reference to the node
		    Remove it, create a new node based on the
				next next page, then add it to the node **/
	  var node = document.getElementById("text");
	  node.removeChild(node.firstChild);
		var newTextNode = document.createTextNode(aboutus_pages[aboutus_pageNo+1]);
		node.appendChild(newTextNode);
		/** Highlight the correct number of the page index **/		
		switch(aboutus_pageNo) {
			case 1: 
				  document.getElementById("i1").style.color = "#D0790F";
				  document.getElementById("i2").style.color = "white";
					aboutus_pageNo++;
					document.getElementById("topphoto").src = aboutus_images[aboutus_pageNo];
					break;
			case 2: break;
			    /** Don't increase the page number because we are already
					    on the last page. **/
		}
	}
}

function aboutus_previousPage() { 
   /** Make sure the we are not on the first page **/ 
	 if(aboutus_pageNo > 1) {
	   var node = document.getElementById("text");
	   node.removeChild(node.firstChild);	
		 var newTextNode = document.createTextNode(aboutus_pages[aboutus_pageNo-1]);
		 node.appendChild(newTextNode);
		 switch(aboutus_pageNo) {
			 case 1: break;

			 case 2: document.getElementById("i2").style.color = "#D0790F";
				  document.getElementById("i1").style.color = "white";
					aboutus_pageNo--;
					document.getElementById("topphoto").src = aboutus_images[aboutus_pageNo];
					break;
		 }		 
	}
}



	
		/*----------FUNCTION FOR ABOUT US PAGE-------------*/

	function viewBob() {
		document.getElementById("page1").style.visibility = "hidden";
		document.getElementById("page2").style.visibility = "visible";
		document.getElementById("i1").style.color = "#D0790F";
		document.getElementById("i2").style.color = "white";
		document.getElementById("photo").src = "graphics/photos/bob1.jpg";
	}

	function viewJeanie() {
		document.getElementById("page2").style.visibility = "hidden";
		document.getElementById("page1").style.visibility = "visible";
		document.getElementById("i2").style.color = "#D0790F";
		document.getElementById("i1").style.color = "white";
		document.getElementById("photo").src = "graphics/photos/jeanie1.jpg";
	}




/* 	Rollover functions for the links in the lower content panes */

/* 	This funtion can be used by any element that want it's
	border to change color. The calling element should 
	provide the new color border and it ID as arguments 
*/


function changeBorder(id, color) {
	var element = document.getElementById(id);
	element.style.borderColor = color;
}




