//Popup Window Radio LIve

function popUpStats(url){
	window.open(url,"ESTADISTICAS","width=760,height=500,toolbars=0,scrollbars=0")
}


// VENTANA POPUP DOCUMENTOS//

var num=Math.floor (Math.random()*1000000);
function popupdocs(p, l, t, w, h) {
 var windowprops = "location=no,scrollbars=no,menubars=no,toolbars=no,resizable=no" + ",left=" + l + ",top=" + t + ",width=" + w + ",height=" + h;
 var URL = p;
 popup = window.open(URL,"MenuPopup1",windowprops);
}

// VENTANA POPUP MULTIMEDIA CORO//

var num=Math.floor (Math.random()*1000000);
function popupcoral(p, l, t, w, h) {
 var windowprops = "location=no,scrollbars=no,menubars=no,toolbars=no,resizable=no" + ",left=" + l + ",top=" + t + ",width=" + w + ",height=" + h;
 var URL = p;
 popup = window.open(URL,"MenuPopup2",windowprops);
}

// VENTANA POPUP BIBLICO//

var num=Math.floor (Math.random()*1000000);
function popupbiblico(p, l, t, w, h) {
 var windowprops = "location=no,scrollbars=yes,menubars=no,toolbars=no,resizable=no" + ",left=" + l + ",top=" + t + ",width=" + w + ",height=" + h;
 var URL = p;
 popup = window.open(URL,"MenuPopup3",windowprops);
}

// VENTANA POPUP AGENDA//

var num=Math.floor (Math.random()*1000000);
function popupagenda(p, l, t, w, h) {
 var windowprops = "location=no,scrollbars=yes,menubars=no,toolbars=no,resizable=no" + ",left=" + l + ",top=" + t + ",width=" + w + ",height=" + h;
 var URL = p;
 popup = window.open(URL,"MenuPopup4",windowprops);
}

// VENTANA POPUP PUBLICACIONES//

var num=Math.floor (Math.random()*1000000);
function popuppublicaciones(p, l, t, w, h) {
 var windowprops = "location=no,scrollbars=yes,menubars=no,toolbars=no,resizable=no" + ",left=" + l + ",top=" + t + ",width=" + w + ",height=" + h;
 var URL = p;
 popup = window.open(URL,"MenuPopup5",windowprops);
}

// VENTANA POPUP VIVO//

var num=Math.floor (Math.random()*1000000);
function popupvivo(p, l, t, w, h) {
 var windowprops = "location=no,scrollbars=no,menubars=no,toolbars=no,resizable=no" + ",left=" + l + ",top=" + t + ",width=" + w + ",height=" + h;
 var URL = p;
 popup = window.open(URL,"MenuPopup6",windowprops);
}

// VENTANA POPUP ATENCION ONLINE//
var num=Math.floor (Math.random()*1000000);
function popupatencion(p, l, t, w, h) {
 var windowprops = "location=no,scrollbars=no,menubars=no,toolbars=no,resizable=no" + ",left=" + l + ",top=" + t + ",width=" + w + ",height=" + h;
 var URL = p;
 popup = window.open(URL,"MenuPopup7",windowprops);
}

// CUENTA REGRESIVA//

function getTime() {
now = new Date();
y2k = new Date("Nov 2 2006 00:00:00");
days = (y2k - now) / 1000 / 60 / 60 / 24;
daysRound = Math.floor(days);
hours = (y2k - now) / 1000 / 60 / 60 - (24 * daysRound);
hoursRound = Math.floor(hours);
minutes = (y2k - now) / 1000 /60 - (24 * 60 * daysRound) - (60 * hoursRound);
minutesRound = Math.floor(minutes);
seconds = (y2k - now) / 1000 - (24 * 60 * 60 * daysRound) - (60 * 60 * hoursRound) - (60 * minutesRound);
secondsRound = Math.round(seconds);
sec = (secondsRound == 1) ? " segundo" : " segundos";
min = (minutesRound == 1) ? " minuto" : " minutos, ";
hr = (hoursRound == 1) ? " hora" : " horas, ";
dy = (daysRound == 1)  ? " día" : " días "
document.timeForm.input1.value = "     Faltan " + daysRound  + dy + "";
newtime = window.setTimeout("getTime();", 1000);
}

function popUp(url){
	window.open(url,"pop","width=590,height=500,toolbars=0,scrollbars=1")
}

// SOLUCION FLASH //

function runSWF(archivo, ancho, alto, version, bgcolor, id,idm, menu, FlashVars, quality, allowScriptAccess) {
  if(version!=""){
  	var version_data=version;
  }else{
  	var version_data="6,0,0,0";
  }
  
  if(menu!=""){
  	menu_data=menu;
  }else{
  	menu_data=false;
  }
  if(bgcolor!=""){
  	var bgcolor_data=bgcolor;
  }else{
  	var bgcolor_data="#FFFFFF";
  }
  if(id!=""){
  	id_data=id;
  }else{
  	id_data="flashMovie";
  }
  if(quality!=""){
  	quality_data=quality;
  }else{
  	quality_data="high";
  }
  if(allowScriptAccess!=""){
  	allowScriptAccess_data=allowScriptAccess;
  }else{
  	allowScriptAccess_data="always";
  }
  
  var quality="high"; 
  
  document.write('<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version='+version_data+'" width='+ancho+' height='+alto+' id='+id_data+'>\n');
  document.write('<param name="movie" value='+archivo+'>\n');
  document.write('<param name="allowScriptAccess" value='+allowScriptAccess_data+'>\n');
  document.write('<param name="quality" value='+quality_data+'>\n');
  document.write('<param name="FlashVars" value='+FlashVars+'>\n');
  document.write('<param name="bgcolor" value='+bgcolor_data+'>\n');
  document.write('<param name="menu" value='+menu_data+' >\n');
  document.write('<param name="wmode" value="transparent" >\n');
  document.write('<embed src='+archivo+' bgcolor='+bgcolor_data+' FlashVars='+FlashVars+' menu='+menu_data+' allowScriptAccess='+allowScriptAccess_data+' quality='+quality_data+' pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width='+ancho+' height='+alto+' swLiveConnect=true id='+idm+' wmode="transparent" ></embed>');
  document.write('</object>\n');
}