//#### ERRORES
function detenerError() {
return true 
} 
window.onerror=detenerError;

//####### DETECCIÓN DEL NAVEGADOR
IE = navigator.appName=="Microsoft Internet Explorer";
NS = navigator.appName=="Netscape";
bVer = parseInt(navigator.appVersion);
var radval = 0;
var newWin=null;

function popup(loc, name, width, height, scroll) {
	if (scroll == 'yes'){
	scroll = 'yes';
	}else{
	scroll = 'no';
	}
        var _params = "width="+width+",height="+height+",resizable=no, scrollbars="+scroll+",status=no";

        // CENTER ON BROWSERS WHICH SUPPORT JSCRIPT 1.2
        if (bVer >= 4) {
                 _left = ( (screen.width-width) >>1 );
                 _top = ( (screen.height-height) >>1 );
        } else {
                 _left = ( (800-width) >>1 );
                 _top = ( (600-height) >>1 );
        }

        if (IE) _params += ",top=" + _top + ",left=" + _left;
        else if (NS) _params += ",screenX=" + _left + ",screenY=" + _top;
        
		newWin = window.open(loc, name, _params);
        if ( newWin!=null && !(IE && bVer<5) )
        newWin.focus(); // MSIE4 DOESN'T FOCUS WINDOWS
}

//####### BARRA DEL NAVEGADOR
var message = 'Bienvenido a: estudioadistancia.com';
statuss();
function statuss()
    {
    window.status = message;
    //timerID = setTimeout("statuss()", 25);
}

//####### MENU
function right(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("Denegado...");
return false;
}
return true;
}
document.onmousedown=right;
if (document.layers) window.captureEvents(Event.MOUSEDOWN);
window.onmousedown=right;

   if(window.Event)
   document.captureEvents(Event.MOUSEUP);function nocontextmenu()
   {event.cancelBubble=true
   event.returnValue=false;return false;}function norightclick(e)
   {if(window.Event)
   {if(e.which==2||e.which==3)
   return false;}else
   if(event.button==2||event.button==3)
   {event.cancelBubble=true
   event.returnValue=false;return false;}}document.oncontextmenu=nocontextmenu;document.onmousedown=norightclick;

//####### DESCARGAS
function descarga(url){
	popup( url, 'DESCARGAS', 500, 550, 'yes');
}