- LSformElement_password : Bug dans la vérification du mot de passe via Ajax

This commit is contained in:
Benjamin Renard 2009-05-28 16:07:05 +00:00
parent 3db41221ef
commit c3f6da6fcb

View file

@ -192,14 +192,24 @@ class LSformElement_password extends LSformElement {
if ((isset($_REQUEST['attribute'])) && (isset($_REQUEST['objecttype'])) && (isset($_REQUEST['fieldValue'])) && (isset($_REQUEST['idform'])) && (isset($_REQUEST['objectdn'])) ) {
if (LSsession ::loadLSobject($_REQUEST['objecttype'])) {
$object = new $_REQUEST['objecttype']();
$form = $object -> getForm($_REQUEST['idform']);
$object -> loadData($_REQUEST['objectdn']);
$form = $object -> getForm($_REQUEST['idform']);
if ($form) {
$field=$form -> getElement($_REQUEST['attribute']);
if ($field) {
$val = $field -> verifyPassword($_REQUEST['fieldValue']);
$data = array(
'verifyPassword' => $val
);
}
else {
LSdebug('Impossible de récupérer le LSformElement');
}
}
else {
LSdebug('Impossible de recuperer le LSform.');
}
}
}
}