// JavaScript Document
//
<!--
for (j=0;j<=(ct_mainMenu_IDs.length)-1;j++){
	if (myLanguage == "ct"){
		tempID = ct_mainMenu_IDs[j];
		tempURL = ct_mainMenu_URLs[j];
		tempTXT = ct_mainMenu_TXTs[j];
	}
	if (myLanguage == "es"){
		tempID = es_mainMenu_IDs[j];
		tempURL = es_mainMenu_URLs[j];
		tempTXT = es_mainMenu_TXTs[j];
	}
	if(tempID == myID){
		// Ens trobem a aquesta pàgina, no s'ha de posar link...
		if (tempID == "Programa"){
			if (myID2 == ""){
				document.write('<li id="' + css_IDs[j] + '">' + tempTXT + '</li>');
			} else {
				document.write('<li id="' + css_IDs[j] + '"><a href="' + tempURL + '">' + tempTXT + '</a></li>');
			}
			//----------
			document.write('<ul>');
			for (jj=0;jj<=(ct_mainMenu_IDsPrograma.length)-1;jj++){
				if (myLanguage == "ct"){
					temp2ID = ct_mainMenu_IDsPrograma[jj];
					temp2URL = ct_mainMenu_URLsPrograma[jj];
					temp2TXT = ct_mainMenu_TXTsPrograma[jj];
				}
				if (myLanguage == "es"){
					temp2ID = es_mainMenu_IDsPrograma[jj];
					temp2URL = es_mainMenu_URLsPrograma[jj];
					temp2TXT = es_mainMenu_TXTsPrograma[jj];
				}
				if(temp2ID == myID2){
					// Ens trobem a aquesta pàgina, no s'ha de posar link...
					document.write('<li id="' + css_IDsPrograma[jj] + '">' + temp2TXT + '</li>');
				} else {
					if (temp2ID == "ProgramaPDF"){
						document.write('<li id="' + css_IDsPrograma[jj] + '"><a href="' + temp2URL + '" target="_blank">' + temp2TXT + '</a></li>');
					} else{
						document.write('<li id="' + css_IDsPrograma[jj] + '"><a href="' + temp2URL + '">' + temp2TXT + '</a></li>');
					}
				}
				/*if (temp2ID == "Agendat"){
					document.write('<ul>');
					for (jjj=0;jjj<=(ct_mainMenu_IDsAgenda.length)-1;jjj++){
						if (myLanguage == "ct"){
							temp3ID = ct_mainMenu_IDsAgenda[jjj];
							temp3URL = ct_mainMenu_URLsAgenda[jjj];
							temp3TXT = ct_mainMenu_TXTsAgenda[jjj];
						}
						if (myLanguage == "es"){
							temp3ID = es_mainMenu_IDsAgenda[jjj];
							temp3URL = es_mainMenu_URLsAgenda[jjj];
							temp3TXT = es_mainMenu_TXTsAgenda[jjj];
						}
							if (temp2ID = "Agendat"){
								if(temp3ID == myID2){
									document.write('<li id="' + css_IDsPrograma[jj] + '">' + temp3TXT + '</li>');
								}else{
									document.write('<li id="' + css_IDsPrograma[jj] + '"><a href="' + temp3URL + '">' + temp3TXT + '</a></li>');
								}
							}
						
					}
					document.write('</ul>');
				}*/
				
				/*if (temp2ID == "Jornades"){
					document.write('<ul>');
					for (jjj=0;jjj<=(ct_mainMenu_IDsJornades.length)-1;jjj++){
						if (myLanguage == "ct"){
							temp3ID = ct_mainMenu_IDsJornades[jjj];
							temp3URL = ct_mainMenu_URLsJornada[jjj];
							temp3TXT = ct_mainMenu_TXTsJornada[jjj];
						}
						if (myLanguage == "es"){
							temp3ID = es_mainMenu_IDsJornades[jjj];
							temp3URL = es_mainMenu_URLsJornada[jjj];
							temp3TXT = es_mainMenu_TXTsJornada[jjj];
						}
							if (temp2ID = "Jornades"){
								if(temp3ID == myID2){
									document.write('<li id="' + css_IDsPrograma[jj] + '">' + temp3TXT + '</li>');
								}else{
									document.write('<li id="' + css_IDsPrograma[jj] + '"><a href="' + temp3URL + '">' + temp3TXT + '</a></li>');
								}
							}
						
					}
					document.write('</ul>');
				}*/
			}
			document.write('</ul>');
			//----------
		} else {
			document.write('<li id="' + css_IDs[j] + '">' + tempTXT + '</li>');
		}
	} else {
		document.write('<li id="' + css_IDs[j] + '"><a href="' + tempURL + '">' + tempTXT + '</a></li>');
	}
}
//-->
