document.writeln("<SCRIPT LANGUAGE=javascript>");
document.writeln("<!--");
document.writeln("function acti(id, nom, littoral, golf, thalasso, montagne)");
document.writeln("{");
document.writeln("	this.id = id;");
document.writeln("	this.nom = nom;");
document.writeln("	this.littoral = littoral;");
document.writeln("	this.golf = golf;");
document.writeln("	this.thalasso = thalasso;");
document.writeln("	this.montagne = montagne;");
document.writeln("}");
document.writeln("array_lieu = [new acti(0,'France',1,1,1,1),new acti(1814,'   Alpes du Nord',5,21,0,1742),new acti(1815,'   Alpes du Sud',19,0,0,485),new acti(2632,'   Alsace - Lorraine',22,0,0,33),new acti(1079,'   Aquitaine',423,45,8,0),new acti(2633,'   Auvergne',31,0,0,8),new acti(2634,'   Bourgogne',19,0,0,0),new acti(1076,'   Bretagne',259,42,4,0),new acti(2635,'   Centre',17,0,0,0),new acti(2627,'   Champagne - Ardenne',3,0,0,0),new acti(1339,'   Corse',69,0,0,0),new acti(1081,'   Côte d Azur',569,80,4,0),new acti(1818,'   Jura',0,0,0,3),new acti(1080,'   Languedoc-Roussillon',550,113,0,0),new acti(2636,'   Limousin',20,0,0,0),new acti(2637,'   Midi-Pyrénées',95,0,0,0),new acti(1073,'   Nord / Picardie',28,0,0,0),new acti(3327,'   Nord-Pas-de-Calais',7,0,0,0),new acti(1074,'   Normandie',70,19,0,0),new acti(2638,'   Paris',2,0,0,0),new acti(1077,'   Pays de Loire',215,63,4,0),new acti(2639,'   Poitou Charentes',160,0,0,0),new acti(1432,'   Provence',178,14,0,0),new acti(1816,'   Pyrenées',0,0,0,231),new acti(3211,'   Rhône-Alpes',3,0,0,0),new acti(2630,'   Vallée du Rhône',31,0,0,0),new acti(0,'Suisse',0,0,0,1),new acti(376,'   Grisons',0,0,0,7),new acti(2748,'   Oberland Bernois',0,0,0,8),new acti(386,'   Valais',0,0,0,115),new acti(2758,'   Vaud',0,0,0,12),new acti(0,'Italie',1,0,0,1),new acti(2692,'   Emilie Romagne',12,0,0,0),new acti(2738,'   Lacs Italiens',3,0,0,0),new acti(2694,'   Piemont',0,0,0,4),new acti(2554,'   Sardaigne',7,0,0,0),new acti(2223,'   Toscane',3,0,0,0),new acti(2619,'   Trentino Alto Adige',0,0,0,9),new acti(2725,'   Veneto',3,0,0,0),new acti(0,'Autriche',0,0,0,1),new acti(681,'   Haute Autriche',0,0,0,4),new acti(460,'   Pays de Salzbourg',0,0,0,62),new acti(815,'   Styrie',0,0,0,9),new acti(384,'   Tyrol',0,0,0,95),new acti(0,'Allemagne',0,0,0,1),new acti(2340,'   Sauerland',0,0,0,2),new acti(0,'Espagne',1,0,0,0),new acti(2526,'   Andalousie',16,0,0,0),new acti(2032,'   Catalogne',311,0,0,0),new acti(2534,'   Communauté Valencienne',73,0,0,0)];");
document.writeln("function clean_select(select)");
document.writeln("{");
document.writeln("	while (select.length > 1) select.options[1] = null;");
document.writeln("}");
document.writeln("// activite dans la station");
document.writeln("function isInStation(obj, acti_id)");
document.writeln("{");
document.writeln("	var isIn = false;");
document.writeln("	if (acti_id == '1' && obj.littoral >= '1') {isIn = true;}");
document.writeln("	if (acti_id == '2' && obj.golf >= '1') {isIn = true;}");
document.writeln("	if (acti_id == '3' && obj.thalasso >= '1') {isIn = true;}");
document.writeln("	if (acti_id == '4' && obj.montagne >= '1') {isIn = true;}");
document.writeln("	return isIn;");
document.writeln("}");
document.writeln("function setActiStation(acti_id)");
document.writeln("{");
document.writeln("	var i;");
document.writeln("	var nb = 0");
document.writeln("	var station = document.travelhorizon.lieu;");
document.writeln("	clean_select(station);");
document.writeln("	for (i=0; i<array_lieu.length; i++)");
document.writeln("	{");
document.writeln("		if (isInStation(array_lieu[i], acti_id) || acti_id == '')");
document.writeln("		{");
document.writeln("			nb++;");
document.writeln("			station[nb] = new Option(array_lieu[i].nom, array_lieu[i].id);");
document.writeln("		}");
document.writeln("	}");
document.writeln("}");
document.writeln("function init_select(value)");
document.writeln("{");
document.writeln("	var form1 = document.travelhorizon;");
document.writeln("	var station = form1.lieu;");
document.writeln("	var station_index = station.selectedIndex;");
document.writeln("	setActiStation(value);");
document.writeln("	if (station_index > 0)");
document.writeln("	{");
document.writeln("		station.selectedIndex = station_index;");
document.writeln("	}");
document.writeln("}");
document.writeln("function valide_form()");
document.writeln("{");
document.writeln("	var form = document.travelhorizon;");
document.writeln("	if (form.lieu[form.lieu.selectedIndex].value == 0)");
document.writeln("	{");
document.writeln("		alert('Merci de choisir une région !');");
document.writeln("		return false;");
document.writeln("	}");
document.writeln("	if(form.date_debut.selectedIndex == 0)");
document.writeln("	{");
document.writeln("		alert('Vous n avez pas précisé la date d arrivée !');");
document.writeln("		return false;");
document.writeln("	}");
document.writeln("	form.submit();");
document.writeln("}");
document.writeln("function select_value(select)");
document.writeln("{");
document.writeln("return select[select.selectedIndex].value;");
document.writeln("}");
document.writeln("//-->");
document.writeln("</SCRIPT>");
