
	//funcion para obtener las respuestas de las encuestas con ajax
	function checkLogin(login, pass)
	{
	 
	    var acceso = QSContentManager.web.frontend.generalColegios.checkLogin(login,pass);
	    //alert(acceso.value);
	   if(acceso.value == 1){
		tableLog.style.display = 'none';
		tableUserLogin.style.display = 'block';
	
	  var nombre = QSContentManager.web.frontend.generalColegios.getNombre(login);
	  //alert(nombre.value);
      lblLoginUsuario.innerHTML = nombre.value;
      var enlace = QSContentManager.web.frontend.generalColegios.getEnlace(login,pass);
      //alert(enlace.value);
      if(enlace.value == '#'){
      enlaceAdmin.href = '#';
      }else{
      trAdmin.style.display = 'block';
      
      enlaceAdmin.href = enlace.value;
      }
      }else if(acceso.value == -1){
      alert('Contraseņa caducada');
	   }else{
		alert('Acceso no permitido');
           }

	}
	
	function checkLogout()
	{
	    tableLog.style.display = 'block';
		tableUserLogin.style.display = 'none';
        trAdmin.style.display = 'none';
        enlaceAdmin.href = '#';
        QSContentManager.web.frontend.generalColegios.doLogout();
	}
	
    function cambiarIdioma(id)
	{
	    
	    var pagina = QSContentManager.web.frontend.general.cambiaIdioma(id);
	    //alert(id);
	    //alert(pagina.value);
	    window.history.go(0); 

	}
	
	function cambiarIdiomaColegio(id)
	{
	    
	    var pagina = QSContentManager.web.frontend.generalColegios.cambiaIdioma(id);
	    //alert(id);
	    //alert(pagina.value);
	    window.history.go(0); 

	}