// JavaScript Document
/***************************\
 * Services Descriptions  *              *
\***************************/
/* Stric Format 
	title + objectIndex = some title
	image + objectIndex = the src favoryte image for the service
	golink + objectIndex = href link rute
	show + objectIndex = the link text
	text + objectIndex = put here your description about the service.
*/
// For example,the same text on index.html page, we need write this:
//(objectIndex = 0)
title0 = "Bienvenido a Space";
image0 = "images/bienvenido.jpg";
golink0 = "es/home.php";
showlink0 = "Leer mas..";
text0 = "<b>SPACE</b> que significa: San Pedro de Atacama Celestial Explorations, comenzo en Septiembre de 2003, y ha seguido progresando. Nuestra principal actividad es el Tour Astronomico, con el cual ya hemos recibido mas de 25000 participantes. Ahora ofrecemos una completa solucion desde personas que solo quieren vivir la experiencia de observar y comprender un cielo estrellado, hasta Instituciones Profesionales que solicitan que nos encarguemos de sus telescopios de investigacion.";

// Star Tour
title1 = "Tour Astronomico";
image1 = "images/terasse.jpg";
golink1 = "es/tour.php";
showlink1 = "Leer mas...";
text1 = "Ofrecemos un tour general cada noche despejada, a excepcion de periodos breves cerca de la Luna llena. Tambien ofrecemos tures especializados y arriendo de equipos para astronomos aficionados.";

// Atacama Lodges
title2 = "Atacama Lodge";
image2 = "images/atacamalodge/entrada4-r.jpg";
golink2 = "es/lodge.php";
showlink2 = "Leer mas...";
text2 = "Atacama Lodge se ubica a pocos kilometros al sur de San Pedro de Atacama, frente a los Andes, muy cerca del triple punto fronterizo entre Chile, Argentina y Bolivia.";

// Telescope Rental
title3 = "Arrendar telescopios";
image3 = "images/abritaka.jpg";
golink3 = "es/telerent.php";
showlink3 = "Leer mas...";
text3 = "Para arriendo de telescopios tenemos disponibles, tanto para observacion, como para fotografia. Si usted arrienda cualquiera de los equipos, entendemos que posee el conocimiento para manejarlos.";

// Telescope Hosting
title4 = "Telescope Hosting";
image4 = "images/C14.jpg";
golink4 = "es/telehost.php";
showlink4 = "Leer mas...";
text4 = "Ya albergamos 3 telescopios de diferentes grupos, llegaran mas el 2009.";

// Telescope Rental Time
title5 = "Arriendo de telescopio ";
image5 = "images/n1365_filtered.jpg";
golink5 = "teletime/teletime.php?lang=es";
showlink5 = "Leer mas...";
text5 = "Muy pronto estara disponible el arriendo de tiempo de telescopio via internet, donde astronomos de todo el mundo podran fotografiar el cielo de Chile";

/*******************************************************\
 *  Funcion que escribe el objeto                      *
\*******************************************************/
function writeObject(title,image,text,golink,showlink)
{
	var htm2 = "<h2>" + title + "</h2>";
	htm2+= "<img src=\"" + image + "\"/>";
	htm2+= "<p>" + text + "</p>";
	htm2+= "<a href=\"" + golink + "\" Style='float:right;'\">" + showlink + "</a>";
	document.getElementById("obj").innerHTML = htm2;
}
/*******************************************************\
 *  Function: show(ObjectIndex)                        *
\*******************************************************/
function show(num)
{
	switch(num)
	{
		case "0":
			writeObject(title0,image0,text0,golink0,showlink0);
			break;
		case "1":
			writeObject(title1,image1,text1,golink1,showlink1);
			break;
		case "2":
			writeObject(title2,image2,text2,golink2,showlink2);
			break;
		case "3":
			writeObject(title3,image3,text3,golink3,showlink3);
			break;
		case "4":
			writeObject(title4,image4,text4,golink4,showlink4);
			break;
		case "5":
			writeObject(title5,image5,text5,golink5,showlink5);
			break;
	}
}
