function FP_swapImg() {//v1.0
  var doc=document,args=arguments,elm,n; doc.$imgSwaps=new Array(); for(n=2; n<args.length;
  n+=2) { elm=FP_getObjectByID(args[n]); if(elm) { doc.$imgSwaps[doc.$imgSwaps.length]=elm;
  elm.$src=elm.src; elm.src=args[n+1]; } }
}

function FP_preloadImgs() {//v1.0
  var d=document,a=arguments; if(!d.FP_imgs) d.FP_imgs=new Array();
  for(var i=0; i<a.length; i++) { d.FP_imgs[i]=new Image; d.FP_imgs[i].src=a[i]; }
}

function FP_getObjectByID(id,o) {//v1.0
  var c,el,els,f,m,n; if(!o)o=document; if(o.getElementById) el=o.getElementById(id);
  else if(o.layers) c=o.layers; else if(o.all) el=o.all[id]; if(el) return el;
  if(o.id==id || o.name==id) return o; if(o.childNodes) c=o.childNodes; if(c)
  for(n=0; n<c.length; n++) { el=FP_getObjectByID(id,c[n]); if(el) return el; }
  f=o.forms; if(f) for(n=0; n<f.length; n++) { els=f[n].elements;
  for(m=0; m<els.length; m++){ el=FP_getObjectByID(id,els[n]); if(el) return el; } }
  return null;
}

var pong;
function makeArray(n){
  this.length = n;
  for (i=1;i<=n;i++){
    this[i]=0;
  }
  return this;
}

function displayDate() {
  var this_month = new makeArray(12);
  this_month[0]  = "Enero";
  this_month[1]  = "Febrero";
  this_month[2]  = "Marzo";
  this_month[3]  = "Abril";
  this_month[4]  = "Mayo";
  this_month[5]  = "Junio";
  this_month[6]  = "Julio";
  this_month[7]  = "Agosto";
  this_month[8]  = "Septiembre";
  this_month[9]  = "Octubre";
  this_month[10] = "Noviembre";
  this_month[11] = "Diciembre";
  var this_day_e = new makeArray(7);
  this_day_e[0]  = "Domingo";
  this_day_e[1]  = "Lunes";
  this_day_e[2]  = "Martes";
  this_day_e[3]  = "Mi\xe9rcoles";
  this_day_e[4]  = "Jueves";
  this_day_e[5]  = "Viernes";
  this_day_e[6]  = "Sabado";
  var today = new Date();
  var day   = today.getDate();
  var month = today.getMonth();
  var year  = today.getYear();
  var dia = today.getDay();
  if (year < 1000) {
      year += 1900; }
  return( " " + this_day_e[dia] + " " + day + " de " + this_month[month] + " del " + year);
}

function popUpAviso(URL) {
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=380,height=260,left = 15,top = 15');");
}

function popUpNovio(URL) {
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=288,height=216,left = 75,top = 75');");
}

function popUpCertificado(URL) {
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=710,height=479,left = 10,top = 10');");
}

function popUpCCamadaD(URL) {
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=363,height=500,left = 10,top = 10');");
}

function popUpCarne(URL) {
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=247,height=155,left = 75,top = 75');");
}

function popUpExpo(URL) {
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=498,height=285,left = 70,top = 70');");
}

function popUpwed01(URL) {
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=499,height=376,left = 75,top = 75');");
}

function popUpwed02(URL) {
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=0,width=517,height=560,left = 45,top = 45');");
}

function popUpSoc01(URL) {
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=0,width=517,height=560,left = 45,top = 45');");
}

function popUpCalendar(URL) {
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=0,width=555,height=402,left = 45,top = 45');");
}

function popUpMor01(URL) {
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=0,width=517,height=560,left = 45,top = 45');");
}

function popUpFB(URL) {
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=0,width=317,height=400,left = 45,top = 45');");
}

function abrir(pagina) {
  x = (screen.width - 600) / 2;
  y = (screen.height - 250) / 2;
  var opciones=("toolbar=no, location=no, directories=no, status=no, menubar=no ,scrollbars=no, resizable=no, width=700, height=299");
  window.open(pagina,"",opciones);
  moveTo(x, y);
}

function popUpDexter(URL) {
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=768,height=548,left=10,top=10');");
}

function popupCard(URL) {
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=336,height=212,left=30,top=80');");
}

function popupCint(URL) {
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=150 height=450,left=20,top=20');");
}

function bderecho(e) { 
	if (navigator.appName == 'Netscape' && (e.which == 3 || e.which == 2)) 
		return false; 
	else if (navigator.appName == 'Microsoft Internet Explorer' && (event.button == 2 || event.button == 3)) { 
		alert("\n\n    \xA9 - 2007 - 2010\n\n    Desarrollado por ARROBA DATA E.I.R.L.                \n    Calle Tintoretto 284, San Borja\n    Lima 41 - Per\xfa\n    Tel\xe9fono: (51 1) 224-7587\n    Contacto: Ing. Jorge A. Landa Niada\n    eMail: jlanda@arrobadata.com\n\n    vis\xedtenos en www.arrobadata.com\n\n"); 
		return false; 
	} 
	return true; 
	} 
  if (document.layers) window.captureEvents(Event.MOUSEDOWN); 
  window.onmousedown=bderecho; 
  document.onmousedown=bderecho; 
  
function jsClock(){
  var time = new Date()
  var hour = time.getHours()
  var minute = time.getMinutes()
  var second = time.getSeconds()
  var temp = "" + ((hour > 12) ? hour - 12 : hour)
  if(hour==0) temp = "12"
  if(temp.length==1) temp = " " + temp
  temp += ((minute < 10) ? ":0" : ":") + minute
  temp += ((second < 10) ? ":0" : ":") + second
  temp += (hour >= 12) ? " PM" : " AM"
  document.clockForm.digits.value = temp
  id = setTimeout("jsClock()",1000)
}

function mueveReloj(){ 
	momentoActual = new Date() 
	hora = momentoActual.getHours() 
	if (hora<10) hora = "0" + hora 
		minuto = momentoActual.getMinutes() 
	if (minuto<10) minuto = "0" + minuto 
		segundo = momentoActual.getSeconds() 
	if (segundo<10) segundo = "0" + segundo 
		horaImprimible = hora + ":" + minuto + ":" + segundo 
		cambiaTexto(horaImprimible) 
		setTimeout("mueveReloj()",1000) 
}
	  
function cambiaTexto(nuevaHora){ 
	xInnerHtml('capareloj',nuevaHora)
}

function hide_infoejemplar(param)
{
	if (param == "frame1")	{
		self.div_frame1.style.display='';
		self.div_frame2.style.display='none';
		self.div_frame3.style.display='none';
		self.div_frame4.style.display='none';
	}
	if (param == "frame2")	{
		self.div_frame1.style.display='none';
		self.div_frame2.style.display='';
		self.div_frame3.style.display='none';
		self.div_frame4.style.display='none';
	}
	if (param == "frame3")	{
		self.div_frame1.style.display='none';
		self.div_frame2.style.display='none';
		self.div_frame3.style.display='';
		self.div_frame4.style.display='none';
	}
	if (param == "frame4")	{
		self.div_frame1.style.display='none';
		self.div_frame2.style.display='none';
		self.div_frame3.style.display='none';
		self.div_frame4.style.display='';
	}
}

function abrirjuez(pagina) {
	var opciones=("toolbar=no, location=no, directories=no, status=no, menubar=no ,scrollbars=yes, resizable=no, width=500, height=500, left=30, top=30");
	window.open(pagina,"",opciones);
}

function abrirhandler(pagina) {
	var opciones=("toolbar=no, location=no, directories=no, status=no, menubar=no ,scrollbars=no, resizable=no, width=500, height=392, left=30, top=30");
	window.open(pagina,"",opciones);
}

function popupTrofeo1(URL) {
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=336,height=212,left=30,top=80');");
}

function popupTrofeo2(URL) {
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=448,height=225,left=30,top=80');");
}

function popupTrofeo3(URL) {
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=240,height=416,left=30,top=80');");
}

function popupTitulo(URL) {
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=666,height=480,left=10,top=10');");
}

function popupMapa01(URL) {
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,width=375,height=400,left=10,top=10');");
}

function abrir(pagina) {
	x = (screen.width - 600) / 2;
	y = (screen.height - 250) / 2;
	var opciones=("toolbar=no, location=no, directories=no, status=no, menubar=no ,scrollbars=no, resizable=no, width=600, height=250");
	window.open(pagina,"",opciones);
}

function ventanaAD(URL,A1,A2,A3,A4) {
  day = new Date();
  id = day.getTime();
  eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=1,location=0,statusbar=0,menubar=0,resizable=0,width=" + A1 + ",height=" + A2 + ",left=" + A3 + ",top=" + A4 + "');");
}
