login.php 1.7 KB

1234567891011121314151617181920212223242526272829303132
  1. <?php
  2. global $conf,$myUser;
  3. $loginMenu = array();
  4. Plugin::callHook("menu_login", array(&$loginMenu));
  5. uasort ($loginMenu , function($a,$b){return $a['sort']>$b['sort']?1:-1;});
  6. ?>
  7. <div id="loginForm" class="form-inline mt-mb-0 login-form">
  8. <label for="login">Identifiant</label>
  9. <input name="login" id="login" maxlength="260" class="form-control form-control-sm mb-2" type="text" required autofocus="true" autocomplete="username">
  10. <label for="password">Mot de passe</label>
  11. <input data-type="password" name="password" id="password" class="form-control form-control-sm " type="password" required autocomplete="current-password">
  12. <div class="form-check connexion-remember mb-1" title="Cocher la case pour enregistrer la session de connexion">
  13. <label class="form-check-label pointer" onclick="event.stopPropagation();"><input data-type="checkbox" class="" type="checkbox" id="rememberMe" name="rememberMe"> Rester connecté</label>
  14. </div>
  15. <div class="btn btn-primary btn-sm btn-login w-100" title="Connexion" id="login-button" onclick="core_login(this)" tabindex="0">
  16. <i class="fas fa-fw fa-sign-in-alt"></i> Se connecter</div>
  17. <?php foreach($loginMenu as $item): ?>
  18. <?php if(isset($item['custom'])):
  19. echo $item['custom'];
  20. else: ?>
  21. <a class="login-menu-item" href="<?php echo $item['url']; ?>">
  22. <?php echo (isset($item['icon'])?'<i class="'.$item['icon'].'"></i> ':'').$item['label']; ?>
  23. </a>
  24. <?php endif; ?>
  25. <?php endforeach; ?>
  26. <?php if($conf->get('password_allow_lost')): ?>
  27. <a href="account.lost.php" title="Modifier son mot de passe grâce à un lien de récupération reçu par email" class="d-block w-100 text-center mt-1 lost-password">Mot de passe oublié ?</a>
  28. <?php endif; ?>
  29. </div>