assign('xorg_title','Polytechnique.org - Acces SMTP/NNTP'); $uid = Session::getInt('uid'); $pass = Env::get('smtppass1'); $log = Session::getMixed('log'); if ( Env::get('op') == "Valider" && Env::get('smtppass1') == Env::get('smtppass2') && strlen($pass) >= 6 ) { $globals->xdb->execute('update auth_user_md5 set smtppass = {?} where user_id = {?}', $pass, $uid); $page->trig('Mot de passe enregistré'); $log->log("passwd_ssl"); } elseif (Env::get('op') == "Supprimer") { $globals->xdb->execute('update auth_user_md5 set smtppass = "" where user_id = {?}', $uid); $page->trig('Compte SMTP et NNTP supprimé'); $log->log("passwd_del"); } $res = $globals->xdb->query("select IF(smtppass != '', 'actif', '') from auth_user_md5 where user_id = {?}", $uid); $page->assign('actif', $res->fetchOneCell()); $page->run(); // vim:et:sw=4: ?>