/*Función para mostra la Fecha u Hora de Generación de los Articulos*/
function HoraOFechaGeneracion(ArtHora,ArtFecha,ArtDia,ArtMes,ArtAnio)
{
	var FechaHoy = new Date(); 
	var DiaHoy   = FechaHoy.getDate(); 
	var MesHoy   = FechaHoy.getMonth()+ 1;
	if (navigator.appName == 'Netscape')
		var AnioHoy = FechaHoy.getYear()+1900;
	else
		var AnioHoy = FechaHoy.getYear();
	if (DiaHoy == ArtDia && MesHoy == ArtMes && AnioHoy == ArtAnio)
		document.write('<span class="arrojo10">&nbsp;(' + ArtHora + ')<span/>');
	else
		document.write('<span class="arnegro10">&nbsp;('+ ArtFecha + ')<span/>');
}	

/*Función para la navegación de las Fotos Dinámicas de Portada y de Articulos*/function cambiafoto(tipodecambio,nuevafoto){	/*tipo de cambio = 0 el cambio de la foto se hace por la forma recursiva					 = 1 el cambio de la foto se hace por la navegación de las flechas*/	if (tipodecambio == '0')	{		if (thisPic==lastPic)			thisPic=0;		else			thisPic++;	}	else			thisPic = nuevafoto;	var IZ = arrayimgzoom[thisPic];			/*Se cambia la Foto y sus datos*/	document.images['FotoDinamica'].src=arrayimg[thisPic];	document.getElementById("FotoFA").innerHTML=arrayfa[thisPic];	document.getElementById("FotoZoom").innerHTML=arrayimgzoom[thisPic];		/*Si hay mas de una foto se despliega la navegación de las Fotos por flechas */	if (arrayimg.length > 1)	{		picant = thisPic;		picsig = thisPic;		picant--;		picsig++;		if (picant < 0)			picant = lastPic;		if (picsig > lastPic)			picsig = 0;		var flechaant = '<a href="javascript:cambiafoto(&quot;1&quot;,&quot;' + picant + '&quot;)"><img src="' + Basepath + 'libre/online07/imggc/flechas_izq.gif" width="17" height="19" border="0"/></a>';		if (IZ !== ' ')			 imgfd = "flechas_der.gif";		else			imgfd = "flechas_der_sola.gif";		var flechasig = '<a href="javascript:cambiafoto(&quot;1&quot;,&quot;' + picsig + '&quot;)"><img src="' + Basepath + 'libre/online07/imggc/' + imgfd + '" width="16" height="19" border="0"/></a>';		document.getElementById("FotoAnt").innerHTML = flechaant;		document.getElementById("FotoSig").innerHTML = flechasig;	}	/*Si sólo hay una sóla foto se valida si tiene FotoZoom, si es así se despliega la imágen completa de la lupita*/	else	{			if (IZ !== ' ')		{			document.images['ImgZoom'].src = Basepath + 'libre/online07/imggc/lupa_sola.gif';			document.images['ImgZoom'].width = '23';		}		}			/*Si el tipo de cambio de foto fué recursivo se habilita volver a cambiar la foto en el tiempo establecido*/	if (tipodecambio == '0')	{		var recur_call = "cambiafoto('0','')";		if (arrayimg.length > 1)			timerID = setTimeout(recur_call, interval);	}}function CambiaContenido()
{
    var zonaiframe = LoMasDestacado.location.pathname;
    zonaiframe = zonaiframe.substr(zonaiframe.length - 6,2);
    if (zonaiframe == 'Z6')
    {
        LoMasDestacado.location = "libre/online07/IncludesPortadas/LoMasDestacadoZ7.htm"
        document.images['ImgHMasNoticias'].src="libre/online07/imggc/mas_noticias1.gif";
        document.images['ImgBMasNoticias'].src="libre/online07/imggc/toggle2.gif";
    }
    else
    {
        LoMasDestacado.location = "libre/online07/IncludesPortadas/LoMasDestacadoZ6.htm"
        document.images['ImgHMasNoticias'].src="libre/online07/imggc/mas_noticias0.gif";
        document.images['ImgBMasNoticias'].src="libre/online07/imggc/toggle1.gif";
    }
}

function fotozoomv(direccion)
{	
    var aleatorio = "P"+Math.round(Math.random()*1000);
    LeftPosition = (screen.width)  ? (screen.width-517)/2  : 0; 
	window.open(direccion,aleatorio,'top=0,left=' + LeftPosition + ',width=507,height=815,directories=no,location=no,menubar=no,scrollbars=no,status=no,toolbar=no,resizable=no');
}

function fotozoomh(direccion)
{	
    var aleatorio = "P"+Math.round(Math.random()*1000);
     LeftPosition = (screen.width)  ? (screen.width-752)/2  : 0; 
	window.open(direccion,aleatorio,'top=0,left=' + LeftPosition + ',width=742,height=575,directories=no,location=no,menubar=no,scrollbars=no,status=no,toolbar=no,resizable=no');
}

function fotozoompromo(direccion)
{	
    var aleatorio = "P"+Math.round(Math.random()*1000);
    window.open(direccion,aleatorio,'width=370,height=315,directories=no,location=no,menubar=no,scrollbars=no,status=no,toolbar=no,resizable=no');
}

/*Función para la navegación de las Fotos Dinámicas de Portada y de Articulos*/function zoomcambiafoto(tipodecambio,nuevafoto){	/*tipo de cambio = 0 el cambio de la foto se hace por la forma recursiva					 = 1 el cambio de la foto se hace por la navegación de las flechas*/	if (tipodecambio == '0')	{		if (ZthisPic==ZlastPic)			ZthisPic=0;		else			ZthisPic++;	}	else			ZthisPic = nuevafoto;		/*Se cambia la Foto y sus datos*/	document.images['ZFotoDinamica'].src=zoomarrayimg[ZthisPic];	document.getElementById("ZFotoFA").innerHTML=zoomarrayfa[ZthisPic];			/*Si hay mas de una foto se despliega la navegación de las Fotos por flechas */	if (zoomarrayimg.length > 1)	{		picant = ZthisPic;		picsig = ZthisPic;		picant--;		picsig++;		if (picant < 0)			picant = ZlastPic;		if (picsig > ZlastPic)			picsig = 0;		var flechaant = '<a href="javascript:zoomcambiafoto(&quot;1&quot;,&quot;' + picant + '&quot;)"><img src="../libre/online07/imggc/flechas_izq.gif" width="17" height="19" border="0"/></a>';		var flechasig = '<a href="javascript:zoomcambiafoto(&quot;1&quot;,&quot;' + picsig + '&quot;)"><img src="../libre/online07/imggc/flechas_der_sola.gif" width="16" height="19" border="0"/></a>';		document.getElementById("ZFotoAnt").innerHTML = flechaant;		document.getElementById("ZFotoSig").innerHTML = flechasig;	}		/*Si el tipo de cambio de foto fué recursivo se habilita volver a cambiar la foto en el tiempo establecido*/	if (tipodecambio == '0')	{		var recur_call = "zoomcambiafoto('0','')";		if (zoomarrayimg.length > 1)			timerID = setTimeout(recur_call, interval);	}}function inocente(direccion,liga)
{	
    var aleatorio = "P"+Math.round(Math.random()*1000);
    var height;
    //if (liga == 1)
        height = 320;
    //else
    //    height = 280;
    
	LeftPosition = (screen.width) ? (screen.width-400)/2 : 0; 
	TopPosition = (screen.height) ? (screen.height-height)/2 : 0;
	window.open(direccion,aleatorio,'top=' + TopPosition + ',left=' + LeftPosition + ',width=400,height=' + height +',directories=no,location=no,menubar=no,scrollbars=no,status=no,toolbar=no,resizable=no');
}