Proyecto

General

Perfil

61 manumora
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="es" lang="es">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="author" content="Manu Mora Gordillo" />
<link rel="shortcut icon" type="image/x-icon" href="img/favicon.ico" />
<title>ControlIES - Centros Educativos de Extremadura</title>
<link href="css/helper.css" media="screen" rel="stylesheet" type="text/css" />

<link rel="stylesheet" type="text/css" href="js/jquery/css/ui-lightness/jquery-ui-1.8.9.custom.css"/>
<script language="javascript" src="js/jquery/jquery-1.5.min.js"></script>
<script language="javascript" src="js/jquery/jquery-ui-1.8.9.custom.min.js"></script>

<script language="javascript">

$(function() {
$( "#tabs" ).tabs();
$( "#authButton" ).button({ icons: { primary: "ui-icon-locked"}});
});

function restartStyle(){
$("#form_authentication span").css("color","black");
$('#message').html("");
}

function authentication(){

restartStyle();

$.post('authentication', $("#form_authentication").serialize(), function(data) {
var result = $.parseJSON(data);
switch(result.connection){
case false:{
$('#message').html("Hubo un error en la autenticación").effect("highlight", {"color":"yellow"}, 1000);
break;
}
case true:{
location.href="main.html";
break;
}
default:{
$('#'+result.connection+"Tag").css("color","red");
$('#'+result.connection).effect("highlight", {"color":"yellow"}, 1000).focus();
}
}
});
return false;
}

</script>
</head>
<body>
<h1>&nbsp;&nbsp;Control<span class="fontTitle">IES</span>&nbsp;&nbsp;<span class="subTitle">Centros Educativos de Extremadura</span</h1>

<div id="tabs" class="centerAuth" style="width:350px; margin-top:100px;">
<ul>
<li><a href="#tabs-1">Autenticaci&oacute;n</a></li>
</ul>
<div id="tabs-1">
<img src="img/unlock.png" style="float:right;"/>
<form id="form_authentication" onSubmit="return authentication();">
79 manumora
<p><span id="hostTag">LDAP</span><br><input type="text" id="host" name="host" value="localhost"></p>
61 manumora
<p><span id="userTag">Nombre</span><br><input type="text" id="user" name="user" value="admin"></p>
<p><span id="passwordTag">Contrase&ntilde;a</span><br><input type="password" id="password" name="password"></p><br>
<div id="message" style="text-align:center; font-weight:bold; color:red; "></div>
<p style="text-align:center;"><button id="authButton" style="width:150px;">Autenticar</button>
</form>
</div>
</div>
</body>
</html>