Tengo un código que reconoce día y hora, y según el resultado, cambia el desenlace.
El tema es que hasta hoy, funcionó bien, pero ahora ha dejado de funcionar y no entiendo por qué. Gracias de antemano.
Código ActionScript :
//obtener la hora GMT para decidir a qué página ingresar
//de lunes a viernes y de 12 a 17 hs. ingresamos a index4.html
//el resto de días incluyendo sábados y domingos, vamos a index5.html
//"class" es el marco o iframe destino
myGMT = new Date();
horaU = (myGMT.getUTCHours()-3);
hoyvch = (myGMT.getDate());
if(horaU <= 0){
horaU = 24 + Number(horaU);
}else if(hoyvch == "6"){
hoyvch = "saba";
}else if(hoyvch == "0"){
hoyvch = "domi";
}
horA = (myGMT.getHours());
vch.onRelease = function(){
if(horaU < 12){
getURL("index5.html","class");
}else if(horaU > 16){
getURL("index5.html","class");
}else if(horaU > 11 and hoyvch != "saba" and hoyvch != "domi"){
getURL("index4.html","class");
}else if(horaU < 17 and hoyvch != "saba" and hoyvch != "domi"){
getURL("index4.html","class");
}
}
