Deltacms/core/module/user/view/login/login.php

81 lines
2.1 KiB
PHP
Raw Normal View History

2022-03-06 13:35:21 +01:00
<?php echo template::formOpen('userLoginForm');
// Lexique
$text = [];
$val = $this->getData(['config', 'i18n', 'langAdmin']);
switch ($val) {
case 'fr' :
$text[0] = 'Identifiant';
$text[1] = 'Mot de passe';
$text[2] = 'Annuler';
$text[3] = 'Connexion';
$text[4] = 'Se souvenir de mon identifiant';
$text[5] = 'Mot de passe perdu';
break;
case 'en' :
$text[0] = 'Identifier';
$text[1] = 'Password';
$text[2] = 'Cancel';
$text[3] = 'Connection';
$text[4] = 'Remember my ID';
$text[5] = 'Lost password';
break;
default:
$text[0] = 'Identifiant';
$text[1] = 'Mot de passe';
$text[2] = 'Annuler';
$text[3] = 'Connexion';
$text[4] = 'Se souvenir de mon identifiant';
$text[5] = 'Mot de passe perdu';
break;
}
?>
2022-01-31 09:10:49 +01:00
<div class="row">
<div class="col6">
<?php echo template::text('userLoginId', [
2022-03-06 13:35:21 +01:00
'label' => $text[0],
2022-01-31 09:10:49 +01:00
'value' => $module::$userId
]); ?>
</div>
<div class="col6">
<?php echo template::password('userLoginPassword', [
2022-03-06 13:35:21 +01:00
'label' => $text[1]
2022-01-31 09:10:49 +01:00
]); ?>
</div>
</div>
<?php if ($this->getData(['config', 'connect','captcha'])): ?>
<div class="row">
<div class="col12 textAlignCenter">
<?php echo template::captcha('userLoginCaptcha', [
'limit' => $this->getData(['config','connect', 'captchaStrong']),
'type' => $this->getData(['config','connect', 'captchaType'])
]); ?>
</div>
</div>
<?php endif;?>
<div class="row">
<div class="col6">
2022-03-06 13:35:21 +01:00
<?php echo template::checkbox('userLoginLongTime', true, $text[4], [
2022-01-31 09:10:49 +01:00
'checked' => $module::$userLongtime
]); ?>
</div>
<div class="col6 textAlignRight">
2022-03-06 13:35:21 +01:00
<a href="<?php echo helper::baseUrl(); ?>user/forgot/<?php echo $this->getUrl(2); ?>"><?php echo $text[5]; ?> ?</a>
2022-01-31 09:10:49 +01:00
</div>
</div>
<div class="row">
<div class="col3 offset6">
<?php echo template::button('userLoginBack', [
'href' => helper::baseUrl() . str_replace('_', '/', str_replace('__', '#', $this->getUrl(2))),
'ico' => 'left',
2022-03-06 13:35:21 +01:00
'value' => $text[2]
2022-01-31 09:10:49 +01:00
]); ?>
</div>
<div class="col3">
<?php echo template::submit('userLoginSubmit', [
2022-03-06 13:35:21 +01:00
'value' => $text[3],
2022-01-31 09:10:49 +01:00
'ico' => 'lock'
]); ?>
</div>
</div>
<?php echo template::formClose(); ?>