function ShowError(){
  return true;
}
window.onerror=ShowError;

function abrirventana(pagina,titulo){
w=660;
h=530;
t=(screen.width-w)/2;
l=(screen.height-h)/2-33;
win=window.open(pagina,'','width='+w+',height='+h+',scrollbars=yes,resizable=yes');
win.moveTo(t,l);
win.focus();
}

function abrirventana2(pagina){
w=525;
h=150;
t=(screen.width-w)/2;
l=(screen.height-h)/2-33;
win=window.open(pagina,'','width='+w+',height='+h+',scrollbars=no,resizable=no');
win.moveTo(t,l);
win.focus();
}

function openapp(extra){
 titextra='';
 if(extra) titextra='2';
 abrirventana('attel.php'+extra,'attel'+titextra);
}
//var calWin;
var calObject;
function abreCalendario(object){ 
w=225;
h=270;
l=(screen.width-w)/2;
t=(screen.height-h)/2-33;
  calObject=object;
  calWin=window.open('calendario/cal.php','cal','width='+w+',height='+h+',left='+l+',top='+t+',scrollbars=no,resizable=no');
  calwin.moveTo(t,l);
  calwin.focus();
} 
function cierraCalendario(dia,mes,anno){ 
  if (calObject=='fechaini') {
     document.forms[0].fechainidia.value=dia;
     document.forms[0].fechainimes.value=mes;
     document.forms[0].fechainianno.value=anno;
  } else if(calObject=='fechafin') {
     document.forms[0].fechafindia.value=dia;
     document.forms[0].fechafinmes.value=mes;
     document.forms[0].fechafinanno.value=anno;
	 document.forms[0].submit()
  }else if(calObject=='actafecha') {
     document.forms[0].actafechadia.value=dia;
     document.forms[0].actafechames.value=mes;
     document.forms[0].actafechaanno.value=anno;
  }
}

function pregunta() { 
if (confirm("Hay Disponibilidad ¿Quiere Reservar?.")) { location="reserva2.php";
} }

function hacerreser() {
alert("Su Reserva sera Confirmada en 5 días."); 
document.location='reserva3.php';
} 

