function admision(){
window.open("resultados/","adm","width=400,height=500,top=0,left=40,toolbar=no,directories=no,menubar=no");
}


function popup(a,w,h){
window.open(a,"popup1","width="+w+",height="+h+",top=0,left=40,toolbar=no,directories=no,menubar=no");
}
function popup2(a,w,h){
window.open(a,"popup2","width="+w+",height="+h+",top=0,left=500,toolbar=no,directories=no,menubar=no");
}

function error_imagen() {
window.event.srcElement.style.display = "None";
}

function abririntranet(){
	window.open("http://" + window.location.host + "/" + "intranet/intranet.html","Intranet","width=675,height=575,scrollbars=no");
	}
function abririntraneti(){
	 /*var winreswidth=window.screen.availWidth;
	 var winresheight=window.screen.availHeight;*/
	//window.open("http://" + window.location.host + "/" + "lasamericas/ingresar/index.php","Intranet","width=874,height=600,top=150,left=220,scrollbars=no");
	window.open("ingresar/index.php");
	}

function ErrorImg() {
window.event.srcElement.style.display = "None";
}

function img(b){
document.imagen.src=b;

}
function buscar(a){
location.href=a;
}
function galeria_fotos(a){
window.open("page/galeria_foto/mostrar_fotos.php?"+a,"fotos","width=550,height=540,top=150,left=300,toolbar=no,directories=no,menubar=no");	
}
///////////////COCURSO DE DOCENTE//////////////////////
function open_concurso(aa){
window.open(aa,"lasAméricas","width=600,height=510,top=150,left=550,toolbar=no,directories=no,menubar=no");	
}
function open_nota(){
window.open("page/concurso_docente/nota.php","lasAméricass","width=397,height=290,top=150,left=550,toolbar=no,directories=no,menubar=no");	
}
////////////////////////////////
function  enviar(r,c){
	recibe=document.getElementsByName('derecho[]'); 			
		recibe[r].checked=1		
		frm.action="?page=asig_detalle&c="+c;
		frm.submit();	
			
}
function ver_resultado(){
window.open("page/exam_resultado/exam_resultado.php","lasAméricas","width=405,height=510,top=150,left=550,toolbar=no,directories=no,menubar=no");	
	
/*{
 if (!document.layers&&!document.all&&!document.getElementById)
  {
   paramstp="height=580,width=796,top=0,left=0,scrollbars=yes,location=no"+
   ",directories=no,status=no,menubar=no,toolbar=no,resizable=yes"
   var gwa=window.open("reflejoimg.html","",paramstp);
   if (gwa.focus){gwa.focus();}
   return;
  }
 var movespeed=80;
 var resizespeed=15;
 var winreswidth=window.screen.availWidth;
 var winresheight=window.screen.availHeight;
 var leftspeed=winreswidth/movespeed;
 var topspeed=winresheight/movespeed;
 var movewidth=winreswidth;
 var moveheight=winresheight;
 var widthspeed=winreswidth/resizespeed;
 var heightspeed=winresheight/resizespeed;
 var sizewidth=0;
 var sizeheight=0;
 var gwa=open("page/exam_resultado/exam_resultado.php","","left="+winreswidth+",top="+winresheight+",width=100,height=100,toolbar=no,menubar=no,location=no,status=no,scrollbars=yes,resizable=yes");
 for (move=0;move<movespeed;move++)
  {
   gwa.moveTo(movewidth,moveheight);
   movewidth-=leftspeed;
   moveheight-=topspeed;
  }
 gwa.moveTo("0","0");

 for (size=0;size<resizespeed;size++)
  {
   gwa.resizeTo(sizewidth,sizeheight);
   sizewidth+=widthspeed;
   sizeheight+=heightspeed;
  }
 gwa.resizeTo(winreswidth,winresheight);
 if (gwa.focus){gwa.focus();}
}*/
}



function tab(pestana,panel)
	{
		pst 	= document.getElementById(pestana);
		pnl 	= document.getElementById(panel);
		psts	= document.getElementById('tabs').getElementsByTagName('li');
		pnls	= document.getElementById('paneles').getElementsByTagName('div');
		
		// eliminamos las clases de las pestañas
		for(i=0; i< psts.length; i++)
		{
			psts[i].className = '';
		}
		
		// Añadimos la clase "actual" a la pestaña activa
		pst.className = 'actual';
		
		// eliminamos las clases de las pestañas
		for(i=0; i< pnls.length; i++)
		{
			pnls[i].style.display = 'none';
		}
		
		// Añadimos la clase "actual" a la pestaña activa
		pnl.style.display = 'block';
	}