// JavaScript Document
function crearElemento(tipoelem,idelem,padreelem,imagen,texto){
	nuevoelemento=document.createElement(tipoelem);
	nuevoelemento.id=idelem;
	if(imagen)nuevoelemento.src=imagen;
	if(texto)nuevoelemento.innerHTML=texto;
	document.getElementById(padreelem).appendChild(nuevoelemento);
	return nuevoelemento;
	
}
function crearEnlace(elemento,funcion,otraventana){
	elemento.href=unescape(funcion);
	if(otraventana)elemento.target="_blank";
}
// para borrar todos los hijos
function borrarHijos(capa){
	if(capa){
			while (capa.hasChildNodes())
				capa.removeChild(capa.firstChild);
		}
}
//TRABAJAR CON AJAX//
var xmlhttp;
function objetoAjax(){

		var xmlhttp=false;

		try {


		xmlhttp = new ActiveXObject("Msxml2.XMLHTTP");

		} catch (e1) {

		try {

		xmlhttp = new ActiveXObject("Microsoft.XMLHTTP");

		} catch (e2) {

		xmlhttp = false;

		}

	}
	if(window.XMLHttpRequest){
		xmlhttp = new XMLHttpRequest();
	}
	if (!xmlhttp && typeof XMLHttpRequest!='undefined') {

  		xmlhttp = new XMLHttpRequest();

  }

  return xmlhttp;

 }
var ajax;
var esteidioma;
function cargaAgenda(idioma,anyo)
{
	esteidioma=idioma;
    // Creamos el objeto xmlHttpRequest
    ajax=objetoAjax();
    var URL ='../phpbdd/consultagenda.php?idioma='+idioma+'&anyo='+anyo;
   if(ajax){
		ajax.open("GET",URL,true);
		// Marcar qué función manejará la respuesta
		ajax.onreadystatechange=recogeLineaAgenda;
		ajax.send(null);
	}
}
function recogeLineaAgenda(){
	if(ajax.readyState==4){
		if(ajax.status==200){
			var texto=ajax.responseXML;
			try{
				var mespantalla='';
				var contador=texto.getElementsByTagName('tipo').length;
				document.getElementById('itemsagenda').innerHTML="";
				for(i=0; i<contador; i++){
					estemes=String(texto.getElementsByTagName('mes')[i].childNodes[0].nodeValue);
					crearElemento('br',false,'itemsagenda',false,false);
					if(mespantalla!=estemes){
						crearElemento('br',false,'itemsagenda',false,false);
						icono=crearElemento('img','imagen','itemsagenda',"../images/agenda/silueta.jpg",false);
						if(esteidioma!='jp')salida=crearElemento('p','salidames','itemsagenda',false,estemes.toUpperCase()+'&nbsp;'+texto.getElementsByTagName('anyo')[i].childNodes[0].nodeValue);
						else { mesingles=mesJpEn(estemes);
						crearElemento('p','salidames','itemsagenda',false,mesingles.toUpperCase()+'&nbsp;'+texto.getElementsByTagName('anyo')[i].childNodes[0].nodeValue);
						}
						mespantalla=estemes;
						crearElemento('br',false,'itemsagenda',false,false);
					}
					linea1=crearElemento('p','lineafch'+i,'itemsagenda',false,false);
					try{
						linea1.innerHTML='<b>'+String(texto.getElementsByTagName('tipo')[i].childNodes[0].nodeValue)+'&nbsp; </b>';
						linea1.innerHTML+='<br>';
					}catch(e){}
					try{
						if(esteidioma=='es')
						linea1.innerHTML+='<b>'+String(texto.getElementsByTagName('dia')[i].childNodes[0].nodeValue)+' de '+String(texto.getElementsByTagName('mes')[i].childNodes[0].nodeValue)+' de '+String(texto.getElementsByTagName('anyo')[i].childNodes[0].nodeValue)+'.</b>';
						if(esteidioma=='en')linea1.innerHTML+='<b>'+String(texto.getElementsByTagName('mes')[i].childNodes[0].nodeValue)+' '+String(texto.getElementsByTagName('dia')[i].childNodes[0].nodeValue)+', '+String(texto.getElementsByTagName('anyo')[i].childNodes[0].nodeValue)+'. </b>';
						if(esteidioma=='jp') linea1.innerHTML+='<b>'+String(texto.getElementsByTagName('anyo')[i].childNodes[0].nodeValue)+String(texto.getElementsByTagName('mes')[i].childNodes[0].nodeValue)+String(texto.getElementsByTagName('dia')[i].childNodes[0].nodeValue)+'&nbsp;</b>';
					}catch(e){}
					try{
						linea1.innerHTML+='<b> '+String(texto.getElementsByTagName('hora')[i].childNodes[0].nodeValue)+' </b><br>';
					}catch(e){linea1.innerHTML+='<br>';}
					try{
						linea1.innerHTML+='<b>'+String(texto.getElementsByTagName('ciudad')[i].childNodes[0].nodeValue)+'</b><br>';
					}catch(e){}
					try{
						linea1.innerHTML+=String(texto.getElementsByTagName('titulo')[i].childNodes[0].nodeValue)+'<br>'; 
					}catch(e){}
					try{
						linea1.innerHTML+=String(texto.getElementsByTagName('lugar')[i].childNodes[0].nodeValue)+'<br>';
					}catch(e){linea1.innerHTML+='<br>';}
					try{
						masinfo=String(texto.getElementsByTagName('enlace')[i].childNodes[0].nodeValue);
						crearElemento('a','enlace'+i,'lineafch'+i,false,false);
						crearEnlace(document.getElementById('enlace'+i),masinfo,true);
						if(esteidioma=='es')document.getElementById('enlace'+i).innerHTML+="<u>m&aacute;s informaci&oacute;n</u>";
						else if(esteidioma=='en')document.getElementById('enlace'+i).innerHTML+="<u>visit the web</u>";
						else document.getElementById('enlace'+i).innerHTML+=" 詳細を見る ";
					}catch(e){}
				}//del for
			}//primer try 
			catch(e){//el de arriba
				document.getElementById('itemsagenda').innerHTML="";
				document.getElementById('itemsagenda').innerHTML='<b>'+"No existen datos para ese a&ntilde;o"+'</b>';
			}
			}//del 200
		}//del 4
}//de la funcion
//Transformar el mes del japones al ingles
function mesJpEn(mes){
		if (mes=="年1月")mes="January" ;
		if (mes=="年2月")mes="February";
		if (mes=="年3月")mes="March";
		if (mes=="年4月")mes="April";
		if (mes=="年5月")mes="May";
		if (mes=="年6月")mes="June";
		if (mes=="年7月")mes="July";
		if (mes=="年8月")mes="August";
		if (mes=="年9月")mes="September";
		if (mes=="年10月")mes="October";
		if (mes=="年11月")mes="November";
		if (mes=="年12月")mes="December";
		return mes;
}
var anyoactualidad;
function cargaActualidad(idioma,anyo){
	document.getElementById(anyo).selected=true;
	esteidioma=idioma;
	anyoactualidad=anyo;
    ajax=objetoAjax();
    var URL ='../phpbdd/consultaactualidad.php?idioma='+idioma+'&anyo='+anyo;
   if(ajax){
		ajax.open("GET",URL,true);
		// Marcar qué función manejará la respuesta
		ajax.onreadystatechange=recogeLineaActualidad;
		ajax.send(null);
	}
}
function recogeLineaActualidad(){
	if(ajax.readyState==4){
		if(ajax.status==200){
			texto=ajax.responseXML;
			try{
				var mespantalla='';
				var contador=texto.getElementsByTagName('titulo').length;
				borrarHijos(document.getElementById('contenedoritems'));
				borrarHijos(document.getElementById('contenedoritemsizq'));
				for(i=0; i<contador; i++){
					crearElemento('div','evento'+i,'contenedoritems',false,false);
					atributoClase('evento'+i,"item");
					addEvent(document.getElementById('evento'+i),"mouseover",resalta,false);
					addEvent(document.getElementById('evento'+i),"mouseout",noresalta,false);
					addEvent(document.getElementById('evento'+i),"click",seleccion,false);
					crearElemento('div','foto'+i,'evento'+i,false,false);
					atributoClase('foto'+i,"itemFoto");
					crearElemento('div','texto'+i,'evento'+i,false,false);
					atributoClase('texto'+i,"itemTexto");
					try{
						crearElemento('img','imge'+i,'foto'+i,false,false);
						document.getElementById('imge'+i).src='../images/actualidad/'+anyoactualidad+'/medianas/'+String(texto.getElementsByTagName('imagen')[i].childNodes[0].nodeValue);
					}catch(e){}
					try{
						crearElemento('p','titulo'+i,'texto'+i,false,false);
						atributoClase('titulo'+i,'titulo');
						document.getElementById('titulo'+i).innerHTML=String(texto.getElementsByTagName('titulo')[i].childNodes[0].nodeValue)+'&nbsp;';
					}catch(e){}
					try{
						crearElemento('p','fecha'+i,'texto'+i,false,false);
						atributoClase('fecha'+i,'fecha');
						if(esteidioma=='es')document.getElementById('fecha'+i).innerHTML='<b>'+String(texto.getElementsByTagName('dia')[i].childNodes[0].nodeValue)+'&nbsp;de&nbsp;'+String(texto.getElementsByTagName('mes')[i].childNodes[0].nodeValue)+'&nbsp;de&nbsp;'+String(texto.getElementsByTagName('anyo')[i].childNodes[0].nodeValue)+'&nbsp;</b>';
						if(esteidioma=='en')document.getElementById('fecha'+i).innerHTML='<b>'+String(texto.getElementsByTagName('mes')[i].childNodes[0].nodeValue)+'&nbsp;&nbsp;'+String(texto.getElementsByTagName('dia')[i].childNodes[0].nodeValue)+',&nbsp;&nbsp;'+String(texto.getElementsByTagName('anyo')[i].childNodes[0].nodeValue)+'&nbsp;</b>';
						if(esteidioma=='jp') document.getElementById('fecha'+i).innerHTML='<b>'+String(texto.getElementsByTagName('anyo')[i].childNodes[0].nodeValue)+String(texto.getElementsByTagName('mes')[i].childNodes[0].nodeValue)+String(texto.getElementsByTagName('dia')[i].childNodes[0].nodeValue)+'&nbsp;</b>';
					}catch(e){}
					try{
						crearElemento('div','descri'+i,'texto'+i,false,false);
						atributoClase('descri'+i,'texto');
						parrafo=String(texto.getElementsByTagName('descripcion')[i].childNodes[0].nodeValue);
						palabras=parrafo.split("...");
						document.getElementById('descri'+i).innerHTML= palabras[0]+'&nbsp;...';
					}catch(e){}
				}//del for
				cargaIzquierda(texto,0);
				document.getElementById('imge0').style.border="2px solid #502B15";
				removeEvent(document.getElementById('evento0'),"mouseout",noresalta,false);
				elemclick=document.getElementById('evento0');
			}//primer try
			catch(e){
				borrarHijos(document.getElementById('contenedoritems'));
				borrarHijos(document.getElementById('contenedoritemsizq'));
				crearElemento('p','mensaje','contenedoritems',false,false);
				if(esteidioma=='es')
					document.getElementById('mensaje').innerHTML='<b>'+"No existen datos para ese a&ntilde;o"+'</b>';
			}//del catch
			}//del 200
		}//del 4
}//de la funcion
function cargaIzquierda(arrayelementos, idevento){
	borrarHijos(document.getElementById('contenedoritemsizq'));
	crearElemento('br',false,'contenedoritemsizq',false,false);
	crearElemento('div','eventoizq'+idevento,'contenedoritemsizq',false,false);
	atributoClase('eventoizq'+idevento,'item');
	crearElemento('div','fotoizq'+idevento,'eventoizq'+idevento,false,false);
	atributoClase('fotoizq'+idevento,'itemFoto');
	crearElemento('div','textoizq'+idevento,'eventoizq'+idevento,false,false);
	atributoClase('textoizq'+idevento,'itemTexto');
	try{
		crearElemento('img','imgizq'+idevento,'fotoizq'+idevento,false,false);
		document.getElementById('imgizq'+idevento).src='../images/actualidad/'+anyoactualidad+'/grandes/'+String(texto.getElementsByTagName('imagen')[idevento].childNodes[0].nodeValue);
		//mirar si hago una precarga de imagenes de las imagenes de ese año cuando carga las medianas q deje en un array las grandes
	}catch(e){}
	try{
		crearElemento('p','tituloizq'+idevento,'textoizq'+idevento,false,false);
		atributoClase('tituloizq'+idevento,'titulo');
		document.getElementById('tituloizq'+idevento).innerHTML=String(texto.getElementsByTagName('titulo')[idevento].childNodes[0].nodeValue)+'&nbsp;';
	}catch(e){}
	try{
		crearElemento('p','fechaizq'+idevento,'textoizq'+idevento,false,false);
		atributoClase('fechaizq'+idevento,'fecha');
		if(esteidioma=='es')document.getElementById('fechaizq'+idevento).innerHTML='<b>'+String(texto.getElementsByTagName('dia')[idevento].childNodes[0].nodeValue)+'&nbsp;de&nbsp;'+String(texto.getElementsByTagName('mes')[idevento].childNodes[0].nodeValue)+'&nbsp;de&nbsp;'+String(texto.getElementsByTagName('anyo')[idevento].childNodes[0].nodeValue)+'&nbsp;</b>';
		if(esteidioma=='en')document.getElementById('fechaizq'+idevento).innerHTML='<b>'+String(texto.getElementsByTagName('mes')[idevento].childNodes[0].nodeValue)+'&nbsp;&nbsp;'+String(texto.getElementsByTagName('dia')[idevento].childNodes[0].nodeValue)+',&nbsp;&nbsp;'+String(texto.getElementsByTagName('anyo')[idevento].childNodes[0].nodeValue)+'&nbsp;</b>';
		if(esteidioma=='jp') document.getElementById('fechaizq'+idevento).innerHTML='<b>'+String(texto.getElementsByTagName('anyo')[idevento].childNodes[0].nodeValue)+String(texto.getElementsByTagName('mes')[idevento].childNodes[0].nodeValue)+String(texto.getElementsByTagName('dia')[idevento].childNodes[0].nodeValue)+'&nbsp;</b>';
	}catch(e){}
	try{
		crearElemento('div','descripcionizq'+idevento,'textoizq'+idevento,false,false);
		atributoClase('descripcionizq'+idevento,'texto');
		parrafo=String(texto.getElementsByTagName('descripcion')[idevento].childNodes[0].nodeValue);
		palabras=parrafo.split("...");
		document.getElementById('descripcionizq'+idevento).innerHTML=palabras[0]+'&nbsp;'+palabras[1];
	}catch(e){}
	if(parseInt(getElementStyle(document.getElementById('seccionderecha'),'height')) < parseInt(getElementStyle(document.getElementById('seccionizquierda'),'height')))document.getElementById('seccionderecha').style.height=getElementStyle(document.getElementById('seccionizquierda'),'height');
}
function getElementStyle(elem,CSSStyleProp){
	var stylevalue, camel;
	if(elem){
		if(document.defaultView && document.defaultView.getComputedStyle(elem,"")){
			//ver para W3C DOM
			var comptStyle=document.defaultView.getComputedStyle(elem,"");
			stylevalue=comptStyle.getPropertyValue(CSSStyleProp);
		}else if(elem.currentStyle){
			//generamos la nomenclatura camelCase de propiedades
			//para IE a partir de la version CSS
			var IEStyleProp=CSSStyleProp;
			var re=/-\D/;
			while(re.test(CSSStyleProp)){
				camel=IEStyleProp.match(re)[0].charArt(1).toUpperCase();
				IEStyleProp=IEStyleProp.repale(re,camel);
			}
			stylevalue=elem.currentStyle[IEStyleProp];
		}
	}
	return (stylevalue)? stylevalue:null;
}
//trabajar con eventos
function addEvent(elem,event,func,capture){
	capture=(capture)?capture:false;
	if(elem.addEventListener){
		elem.addEventListener(event,func,capture);
	}
	else if(elem.attachEvent){
		elem.attachEvent("on"+event,func);
	}
	else{
		//para IE/Mac, NN4, y anteriores
		elem["on"+event]=func;
	}
}
function removeEvent(elem,event,func,capture){
	capture=(capture)?capture:false;
	if(elem.removeEventListener){
		elem.removeEventListener(event,func,capture);
	}
	else if(elem.attachEvent){
		elem.detachEvent("on"+event,func);
	}
	else{
		//para IE/Mac, NN4, y anteriores
		elem["on"+event]=null;
	}
}
//selecciona el item de actualidad derecho al principio de la carga selecciona el primero
function resalta(){
	if(navigator.appName == "Microsoft Internet Explorer"){id=event.srcElement.parentNode.id;}
	else{
		id=this.id;
	}
	if(id){
		document.getElementById('imge'+id.substring(6,id.length)).style.border='2px solid #502B15';
		}
}
function noresalta(){
	if(navigator.appName == "Microsoft Internet Explorer"){id=event.srcElement.parentNode.id;}
	else{
		id=this.id;
	}
	if(id){
		document.getElementById('imge'+id.substring(6,id.length)).style.border='2px solid #ffffff';
	}
}
//evento click
var elemclick;
function seleccion(){
	if(navigator.appName == "Microsoft Internet Explorer"){id=event.srcElement.parentNode.id;}
	else{
		id=this.id;
	}
	if(elemclick!=null){
		document.getElementById('imge'+(elemclick.id).substring(6,(elemclick.id).length)).style.border='2px solid #FFFFFF';
		addEvent(elemclick,"mouseover",resalta,false);
		addEvent(elemclick,"mouseout",noresalta,false);
	}
	if(id){
		document.getElementById('imge'+id.substring(6,id.length)).style.border='2px solid #502B15';
		removeEvent(document.getElementById('evento'+id.substring(6,id.length)),"mouseover",resalta,false);
		removeEvent(document.getElementById('evento'+id.substring(6,id.length)),"mouseout",noresalta,false);
		cargaIzquierda(texto,id.substring(6,id.length));
		window.scroll(0,0);
		elemclick=document.getElementById(id);
	}
}
function atributoClase(idelemento,nombreclase){
	if (BrowserDetect.browser == "Explorer"){
		document.getElementById(idelemento).setAttribute("className", nombreclase);
	}else document.getElementById(idelemento).setAttribute("class", nombreclase);
}
function emailValido(elem){
	var str=elem.value;
	var re=/^[\w-]+(\.[\w-]+)*@([\w-]+\.)+[a-zA-Z]{2,7}$/;
	if(!str.match(re))return false;
	else return true;
}
function noEstaVacio(elem){
	var str=elem.value;
	if(str==null || str.length==0)return false;
	else return true;
}
var txtStatus='avisos contacto';
var tempo;
var timeEspera=50;  // tiempo que ha de esperar entre carácter y carácter
var recarga=false;
function correStatus(posStatus){
  if (posStatus < txtStatus.length){
    posStatus+=1;
    if(document.getElementById('error'))
		document.getElementById('error').innerHTML=txtStatus.substring(0,posStatus);
	}
   else  {
	   if (!recarga) return true; 
	   else posStatus=0;
	   }
   tempo=setTimeout("correStatus("+posStatus+")",timeEspera);
 }
 var idioma;
function validarFormulario(idiomacorrecto){
	idioma=idiomacorrecto;
	if(noEstaVacio(document.forms[0].elements["emisor"]) && noEstaVacio(document.forms[0].elements["email"]) && noEstaVacio(document.forms[0].elements["texto"])){
		if(emailValido(document.forms[0].elements["email"])){
			//todo correcto envío mensaje
			enviarFormulario();
			}
		else{
				if(tempo)clearTimeout(tempo);
				document.getElementById('error').innerHTML="";
				if(idioma=='es')txtStatus='Por favor revise su dirección de e-mail. Gracias.';
				if(idioma=='en')txtStatus='Please check his address of e-mail. Thank you.';
				if(idioma=='jp')txtStatus='メールアドレスをご確認ください。';
				correStatus(0);
				document.forms[0].elements["email"].focus(); return false;}
		} 
	else {
		i=0;
		var vacio=new Array(3);
		if(!noEstaVacio(document.forms[0].elements["emisor"])){
			if(idioma=='es')vacio[i]='nombre'; 
			if(idioma=='en')vacio[i]='name';
			if(idioma=='jp')vacio[i]='お名前';
			i++;
		}
		if(!noEstaVacio(document.forms[0].elements["email"])){
			if(idioma=='es' || idioma=='en')vacio[i]='e-mail'; 
			if(idioma=='jp') vacio[i]='メールアドレス';
			i++;
			}
		if(!noEstaVacio(document.forms[0].elements["texto"])){
			if(idioma=='es')vacio[i]='comentario';
			if(idioma=='en')vacio[i]='comment';
			if(idioma=='jp')vacio[i]='コメント';
			i++;
			}
		if(tempo)clearTimeout(tempo);
		document.getElementById('error').innerHTML="";
		//The fields 'comment' and 'subject' are required.
		if(i==1){ 
			if(idioma=='es')txtStatus='El campo '+vacio[0]+' es obligatorio. Por favor revíselo. Gracias.';
			if(idioma=='en')txtStatus='The field '+vacio[0]+' is required. Please check it. Thank you.';
			if(idioma=='jp')txtStatus=vacio[0]+' は入力必須項目です。再度ご確認ください。';
		}
		else if(i==2){
			if(idioma=='es')txtStatus='Los campos '+vacio[0]+' y '+vacio[1]+' son obligatorios. Por favor revíselos. Gracias.';
			if(idioma=='en')txtStatus='The fields '+vacio[0]+' and '+vacio[1]+' are required. Please check them. Thank you.';
			if(idioma=='jp')txtStatus=vacio[0]+' と '+vacio[1]+' は入力必須項目です。再度ご確認ください。';
			}
		else {
			if(idioma=='es')txtStatus='Los campos '+vacio[0]+' , '+vacio[1]+' y '+vacio[2]+' son obligatorios. Por favor revíselos. Gracias.';
			if(idioma=='en')txtStatus='The fields '+vacio[0]+' , '+vacio[1]+' and '+vacio[2]+' are required. Please check them. Thank you.';
			if(idioma=='jp')txtStatus=vacio[0]+' '+vacio[1]+' '+vacio[2]+' は入力必須項目です。再度ご確認ください。';
		}
		correStatus(0);
	}
}
function enviarFormulario(){
	if(tempo)clearTimeout(tempo);
	document.getElementById('error').innerHTML="";
	//document.getElementById('error').innerHTML = '<p style="text-align:center;"><img src="../images/contacto/load.gif"/></p>';
	emis=encodeURIComponent(document.forms[0].elements["emisor"].value);
	emai=document.forms[0].elements["email"].value;
	asun=encodeURIComponent(document.forms[0].elements["asunto"].value);
	men=encodeURIComponent(document.forms[0].elements["texto"].value);
	ajax=objetoAjax();
	if(ajax){
		try{
		ajax.open("POST",'../phpbdd/email.php',false);
		ajax.setRequestHeader("Content-Type","application/x-www-form-urlencoded"); 
		ajax.send("email="+emai+"&emisor="+emis+"&texto="+men+"&asunto="+asun+"&lengua="+idioma);
		respuestaEmail();
		}catch(e1){
			if(idioma=='es')document.getElementById('error').innerHTML='No se ha podido enviar el mensaje. Por favor, int&eacute;ntelo de nuevo. Disculpe las molestias.';
			if(idioma=='en')document.getElementById('error').innerHTML='One could not have sent the e-mail. Please try again. Forgive the inconveniences.';
			if(idioma=='jp')document.getElementById('error').innerHTML='メッセージが送信中にエラーが発生しました。もう一度やり直して下さい。ご迷惑をおかけいたします。;'
		}
	}
}
function respuestaEmail(){
		document.forms[0].elements["emisor"].value='';
		document.forms[0].elements["email"].value='';
		document.forms[0].elements["asunto"].value='';
		document.forms[0].elements["texto"].value='';
		document.getElementById('error').innerHTML= ajax.responseText;
}
var idiomarchivo="elegir";
function cargaNombreArchivo(carpeta,subcarpeta,nombrearchivo,idioma,extension,espectaculo){
	idiomarchivo=idioma;
	if(idiomarchivo!="elegir"){
		if(idiomarchivo!='false')nombre=carpeta+"/"+subcarpeta+"/"+nombrearchivo+idiomarchivo+"."+extension;
		else nombre=carpeta+"/"+subcarpeta+"/"+nombrearchivo+"."+extension;
		if(espectaculo!='false')document.getElementById(carpeta+subcarpeta+espectaculo).href='../phpbdd/descarga.php?file='+nombre;
		else document.getElementById(carpeta+subcarpeta).href='../phpbdd/descarga.php?file='+nombre;
	}
	else {
		if(espectaculo!='false')document.getElementById(carpeta+subcarpeta+espectaculo).href='#';
		else document.getElementById(carpeta+subcarpeta).href='#';
	}
}