Overview
Comment:Correction message login qui ne marche pas
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | dev
Files: files | file ages | folders
SHA1: 9112f10a85a1e2332e716edcd63ddca4f6e79692
User & Date: bohwaz on 2017-06-08 05:37:26
Other Links: branch diff | manifest | tags
Context
2017-06-08
06:11
make_release: ne pas stocker le nom / ID de l'utilisateur check-in: b238ec38d0 user: bohwaz tags: dev
05:37
Correction message login qui ne marche pas check-in: 9112f10a85 user: bohwaz tags: dev
05:37
Utilisation de KD2\Translate pour obtenir la liste des pays check-in: 1c1f650b03 user: bohwaz tags: dev
Changes

Modified src/www/admin/login.php from [16d6682a67] to [0088f1ea18].

21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
..
47
48
49
50
51
52
53
54
55
56

    header('Content-Type: image/gif');
    echo base64_decode("R0lGODlhAQABAIAAAP///////yH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==");

    exit;
}

$fail = false;

// Soumission du formulaire
if (f('login'))
{
    $form->check('login', [
        '_id'       => 'required|string',
        'passe'     => 'required|string',
        'permanent' => 'boolean',
    ]);

    if (!$form->hasErrors() && ($fail = Membres\Session::login(f('_id'), f('passe'), (bool) f('permanent'))))
    {
        Utils::redirect('/admin/');
    }
}

$champs = $config->get('champs_membres');

................................................................................
$champ = $champs->get($config->get('champ_identifiant'));

$tpl->assign('ssl_enabled', empty($_SERVER['HTTPS']) ? false : true);
$tpl->assign('prefer_ssl', (bool)PREFER_HTTPS);
$tpl->assign('own_https_url', str_replace('http://', 'https://', utils::getSelfURL()));

$tpl->assign('champ', $champ);
$tpl->assign('fail', $fail);

$tpl->display('admin/login.tpl');







|










|







 







|


21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
..
47
48
49
50
51
52
53
54
55
56

    header('Content-Type: image/gif');
    echo base64_decode("R0lGODlhAQABAIAAAP///////yH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==");

    exit;
}

$login = null;

// Soumission du formulaire
if (f('login'))
{
    $form->check('login', [
        '_id'       => 'required|string',
        'passe'     => 'required|string',
        'permanent' => 'boolean',
    ]);

    if (!$form->hasErrors() && ($login = Membres\Session::login(f('_id'), f('passe'), (bool) f('permanent'))))
    {
        Utils::redirect('/admin/');
    }
}

$champs = $config->get('champs_membres');

................................................................................
$champ = $champs->get($config->get('champ_identifiant'));

$tpl->assign('ssl_enabled', empty($_SERVER['HTTPS']) ? false : true);
$tpl->assign('prefer_ssl', (bool)PREFER_HTTPS);
$tpl->assign('own_https_url', str_replace('http://', 'https://', utils::getSelfURL()));

$tpl->assign('champ', $champ);
$tpl->assign('fail', $login === false);

$tpl->display('admin/login.tpl');