<!-- hide
if (typeof(prependDomain) == "undefined") {
        prependDomain = "";
}

//from flash section
function popArchive(mes,movie) {
	window.open('/canal/flash/poparchmovie.jhtml?mes='+mes+'&movie='+movie,'flashpop','width=320,height=240');
}
function popMesAnterior(mes,restore) {
	window.open('/canal/flash/archivos/pop.jhtml?mes='+ mes.options[mes.selectedIndex].value ,'flashmes','width=420,height=350,scrollbars=yes');
if (restore) mes.selectedIndex=0;
}
function popMesAntLink(mes) {
	window.open('/canal/flash/archivos/pop.jhtml?mes='+ mes ,'flashmes','width=420,height=350,scrollbars=yes');
}
function submitFlash() {
	document.FlashMtv.submit();
}
function FloatBanner()  {
	//window.open('/canal/flash/popup.jhtml','flashpop','top=15,screenx=15,left=15,screeny=15,width=320,height=225');
}

var played = 0;

function FindMyCookie() {
	var theCookie = document.cookie;
	var locMyCookie = theCookie.indexOf("cookieFlash");
	if (locMyCookie == -1)
		played = 0;
	else
		played = 1;
}
function SetCookie()  {
				 var expDate = new Date();
				 expDate.setTime(expDate.getTime() + (1000*60*60*12));
				 document.cookie="cookieFlash=TRUE" + "; expires=" + expDate.toGMTString();
}
//end Flash section

function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);

function MM_preloadImages() { //v3.0 header.jhtml
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_findObj(n, d) { //v4.0
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && document.getElementById) x=document.getElementById(n); return x;
}

function MM_showHideLayers() { //v6.0
  var i,p,v,obj,args=MM_showHideLayers.arguments;
  for (i=0; i<(args.length-2); i+=3) if ((obj=MM_findObj(args[i]))!=null) { v=args[i+2];
    if (obj.style) { obj=obj.style; v=(v=='show')?'visible':(v=='hide')?'hidden':v; }
    obj.visibility=v; }
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}

function MM_openBrWindow(theURL,winName,features) { //v2.0
 	window.open(theURL,winName,features);
}
function launchRSN(varStationID){
        var tuner = false;
        tuner = window.open(prependDomain + '/radio/radiolaunch.jhtml?oparam=radio&serviceSubjectID='+ varStationID + '&A='+ varStationID ,'TUNERLogin','width=700,height=312,toolbar=no,resizable=no,scrollbars=no');
        tuner.focus;
        popCheck(tuner);
}

function Launch(page, width, height){ 
  OpenWin = this.open(page, "vh1p", "toolbar=no, menubar=no ,location=no, scrollbars=no, resizable=no, width=" + width + ", height=" + height + ", top=" + (screen.height/2 - height/2) + ", left=" + (screen.width/2 - width/2) + "\""); 
} 


function abrirMB(abrirMB){
window.open(abrirMB,'mesageBoard','width=764 height=500');
}

function popTerms(){
window.open('/sitewide/legal/index.jhtml','legal','scrollbars=yes,width=600,height=550');
}

function popFlip(loc){
	window.open(loc,'flipbook','width=556,height=486,scrollbars=no');
}

function popFlipbook(flipURL){
	window.open(flipURL,'fotogaleria','top=1,screeny=1,left=1,screenx=1,width=727,height=547,buttons=no,scrollbars=no,location=no,menubar=no,resizable=no,status=no,directories=no,toolbar=no');
}

function popMediaPlayer(flipURL){
	window.open(flipURL,'MediaPlayer','top=1,screeny=1,left=1,screenx=1,width=727,height=547,buttons=no,scrollbars=no,location=no,menubar=no,resizable=no,status=no,directories=no,toolbar=no');
}

function popEmailVideo(emailURL){
	window.open(emailURL,'EmailVideo','top=1,screeny=1,left=1,screenx=1,width=400,height=355,buttons=no,scrollbars=no,location=no,menubar=no,resizable=no,status=no,directories=no,toolbar=no');
}

//Mod. by: Michello
//Being of script for nav menu
//Requires to have the the script call set styles included on the header of the document

function nullit() {return true;}
window.onerror = nullit

	function MakeArray(n){
	   this.length = n
	   for (var i = 1; i<=n; i++) {
	      this[i] = new Image()
	   }
	   return this;
	}
	function omOver(name,number){
		if (document.images){
	      	name.src = over[number].src;
	   	}
	}
	function omOut(name,number){
		if (document.images){
	    	name.src = out[number].src;
	   	}
	}
	
	//var imagename = new Array("","navhome","navnews","navbands","navmusic","navonair","navcommunity","navradio")
	//var gatewayImg =  new Array("","sub_home","sub_news","sub_bands","sub_music","sub_onair","sub_community","sub_radio")
	// Change by Michello
	var imagename = new Array("","navonair","navbands","navextra","navcommunity","navhome","com_intantaneo","com_charla","com_foros","com_correo")
	var gatewayImg =  new Array("","hub_canal","hub_artistaz","hub_extra","hub_comunidad","hub_jom","com_intantaneo","com_charla","com_foros","com_correo")
	
	num = 0
	if (document.images) {
		header_Over = new MakeArray(10);
		header_Out = new MakeArray(10);
		for (imgX=1;imgX<11;imgX++){
		header_Out[imgX] = new Image(); 
		header_Out[imgX].src = "/sitewide/headerfooter/images/" + gatewayImg[imgX] + ".gif";
		header_Over[imgX] = new Image();
		header_Over[imgX].src = "/sitewide/headerfooter/images/" +gatewayImg[imgX] + "_on.gif";
		}
	}
	
	function headerOver(num){
		if (document.images){
	    	eval ("document." + imagename[num] + ".src ='" + header_Over[num].src +"'")
		}
	}
	function headerOut(num){
	
		if ((documentss.images) && (num != gatewayLock)){
		eval ("document." + imagename[num] + ".src ='" + header_Out[num].src +"'")}
		}
	function headerOutX(num){
		if (document.images){
		if(dhtml==0 && (num != gatewayLock)) {
	    	eval ("document." + imagename[num] + ".src ='" + header_Out[num].src +"'")}
		}
	}
	
var NS = (navigator.appName == "Netscape");
mac = navigator.appVersion.indexOf("Mac");
if (mac>=0) {mac=1} else {mac=0}
IE4 = document.all; NS4 = document.layers; NS6a = document.getElementById
if(NS6a && NS) {NS6=1} else {NS6=0}
if ((IE4) || (NS4) || (NS6)) {dhtml=1;}

if(NS4){ origWidth = innerWidth ; origHeight = innerHeight; pageurl = self.location;}

function re() {
	if (NS4) {if (innerWidth != origWidth || innerHeight != origHeight){ 
	//top.location.replace(pageurl) 
	location.reload(true) 
	}}}
	window.onResize = re;

	if (NS4){origWidth = innerWidth;origHeight = innerHeight;}
	
px = ""; menuOn=-1; menuht=130; menuwt=0; ext=0; layerLeftPos=0; flashPresent = 0 ; gatewayLock= -1	;
layerDims_y = new Array ; layerDims_x = new Array

function refConstructor(menuId) {
	if (NS6) {var prefix = "document.getElementById('menu" + menuId + "')"}
	if (IE4) {var prefix = "document.all.menu" + menuId}
	if (NS4) {var prefix = "document.menu" + menuId}
	return prefix;
	}
	
function menuInit() {
	for (layerInit = 0;layerInit<5;layerInit++) {
	var layerRef =  refConstructor(layerInit)
	layerDims_y[layerInit]  = (IE4 || NS6) ? eval(layerRef + ".offsetHeight + menuht") : eval(layerRef + ".clip.height + menuht")
	layerDims_x[layerInit]  = (IE4 || NS6) ? eval(layerRef + ".offsetWidth + 5") : eval(layerRef + ".clip.width + 5")
	}
	if (flashPresent==1){(IE4) ? eval("document.all.flashLayer.style.visibility = 'visible'"):eval("document.flashLayer.visibility = 'visible'");}
	}

function reportEvent(cc) { 
	layerLeftPos  =  (IE4) ? (event.x) - 50 : (cc.pageX) - 50
	var layerRef =  refConstructor(menuOn)
	mousePos_y  =  (IE4) ? event.y + menuht : cc.pageY + menuht
	mousePos_x  =  (IE4) ? event.x : cc.pageX
	
//added variable "MimageMap" to set the top position of the layer depending on the browser

	yMinPos = (IE4) ? (menuht - document.body.scrollTop - MimageMap) : (menuht- MimageMap );
		
	if((mousePos_y >(layerDims_y[menuOn] + menuht + ext)) || ((mousePos_y - menuht) < yMinPos ) || (mousePos_x < (menuwx - 20)) || (mousePos_x > (layerDims_x[menuOn] + menuwx)))
		{ 
		(IE4 || NS6) ? eval(layerRef + ".style.visibility = 'hidden'") : eval(layerRef + ".visibility = 'hidden'");
		v= menuOn+2;
		if (menuOn+1 != gatewayLock) {headerOut(v);};
		menuwt=0;menuOn=-1;
		if(flashPresent==1){
		(IE4) ? eval("document.all.flashLayer.style.visibility = 'visible'"):eval("document.flashLayer.visibility = 'visible'");}
		if (IE4 || NS6) { document.onmousemove = null }
		else{	
		document.releaseEvents(Event.MOUSEMOVE)
		layerLeftPos=0
		}}
 	}

function move() {
	if (IE4) { document.onmouseover = null }
	else{ document.releaseEvents(Event.MOUSEOVER)};
	var layerRef =  refConstructor(menuOn);
	(IE4 || NS6) ? eval(layerRef + ".style.left =" + layerLeftPos) : eval(layerRef + ".left =" + layerLeftPos);
	(IE4 || NS6) ? eval(layerRef + ".style.visibility = 'visible'") : eval(layerRef + ".visibility = 'visible'");
	}

	
//Added micheLayerPos to get position value from menu() function
function xx(setThePos) { 


//Variable declaration to set layer position assigned for IE4 , NS4 ,NS6
var micheLayerPos;
micheLayerPos = setThePos;

	layerLeftPos = (IE4 || NS6) ? ((document.body.offsetWidth - 764)/2 + micheLayerPos + menuOn*46) : ((innerWidth - 764)/2 + micheLayerPos + menuOn*46);
	move(); first=0; menuwx = layerLeftPos;
	if(document.layers) {document.captureEvents(Event.MOUSEMOVE)};
	document.onmousemove = reportEvent 
	ext = 10
	}
	
//Mod by: Michello
//Added thePos to set the position of the  layer menus
function menu(m,getThePos) {

	if (m != menuOn) {
		v = m+2; headerOver(v)
		if(dhtml){
			var layerRef =  refConstructor(menuOn)
			if (menuOn != m && menuOn!=-1){
				v2 = menuOn+2;
				if (menuOn+1 != (gatewayLock)) {headerOut(v2);};
				(IE4 || NS6) ? eval(layerRef + ".style.visibility = 'visible'") : eval(layerRef + ".visibility = 'visible'");
				}
			menuOn = m ;
			if(flashPresent==1){
			(IE4) ? eval("document.all.flashLayer.style.visibility = 'hidden'"):eval("document.flashLayer.visibility = 'hidden'");}
		xx(getThePos);};
		}
	}
		
	window.onload = menuInit
	
//end of script for nav menu

// used for Netscape
//detect browser
bName = navigator.appName;
bVer = parseInt(navigator.appVersion);
// assign base variables
flash = "no"
flashver = "1.0"
action = "ns_exec"
// detect plugin for NS flash 3 version
if (bName=="Netscape") {
	var flashplugin_ref = navigator.plugins["Shockwave Flash"];
	var flash3 = false;
	var flash4 = false;
	var flash5 = false;
								
		if (flashplugin_ref) {
			var flsh5 = flashplugin_ref.description.indexOf("Flash 5");
			var flsh4 = flashplugin_ref.description.indexOf("Flash 4");
			var flsh3 = flashplugin_ref.description.indexOf("Flash 3");
				if (flsh5 != -1) {
					flash5 = true;
				}
				else if (flsh4 != -1) {
					flash5 = true;
				}
				else if (flsh3 != -1) {
					flash5 = true;
				}
		}
}
else if (bName =="Microsoft Internet Explorer") {
	var platform = (navigator.userAgent.indexOf("Mac") != -1) ? "Mac" : "Windows";
	var version = parseFloat(navigator.appVersion);
		if (platform == "Mac") {
			flash5 = flash3 = true;
		}
		else if (version < 4) {
			flash5 = flash3 = true;
		}
		else {
			action = "ie_exec"
		}
}
 
if ( document.cookie.indexOf( "flashOK=true" ) == -1 ) {
	if ( flash5 ) {
		document.cookie = "flashOK=true";
	}
}
//-->
