templates/security/login.html.twig line 98

Open in your IDE?
  1. {% extends 'notloggedin.html.twig' %}
  2. {% block stylesheets %}
  3.     <style>
  4.         html,
  5.         body {
  6.           height: 100%;
  7.         }
  8.         body {
  9.           display: -ms-flexbox;
  10.           display: flex;
  11.           -ms-flex-align: center;
  12.           align-items: center;
  13.           padding-top: 40px;
  14.           padding-bottom: 40px;
  15.           background-color: #f5f5f5;
  16.         }
  17.         .form-signin {
  18.           width: 100%;
  19.           max-width: 330px;
  20.           padding: 15px;
  21.           margin: auto;
  22.         }
  23.         .form-signin .checkbox {
  24.           font-weight: 400;
  25.         }
  26.         .form-signin .form-control {
  27.           position: relative;
  28.           box-sizing: border-box;
  29.           height: auto;
  30.           padding: 10px;
  31.           font-size: 16px;
  32.         }
  33.         .form-signin .form-control:focus {
  34.           z-index: 2;
  35.         }
  36.         .form-signin input[type="email"] {
  37.           margin-bottom: -1px;
  38.           border-bottom-right-radius: 0;
  39.           border-bottom-left-radius: 0;
  40.         }
  41.         .form-signin input[type="password"] {
  42.           margin-bottom: 10px;
  43.           border-top-left-radius: 0;
  44.           border-top-right-radius: 0;
  45.         }
  46.               .bd-placeholder-img {
  47.                 font-size: 1.125rem;
  48.                 text-anchor: middle;
  49.                 -webkit-user-select: none;
  50.                 -moz-user-select: none;
  51.                 -ms-user-select: none;
  52.                 user-select: none;
  53.               }
  54.               @media (min-width: 768px) {
  55.                 .bd-placeholder-img-lg {
  56.                   font-size: 3.5rem;
  57.                 }
  58.               }
  59.               
  60.     </style>
  61. {% endblock %}
  62. {% block body %}
  63.     <body class="text-center">
  64.         <form method="post" class="form-signin">
  65.             <img class="mb-3" width="200" src="{{ asset('/public/uploads/' ~ logo) }}" >
  66.             <h1 class="h3 mb-3 mt-3 font-weight-normal">Inloggen</h1>
  67.             
  68.             <label for="inputUsername" class="sr-only">Gebruikersnaam</label>
  69.             <input type="text" value="{{ last_username }}" name="username" id="inputUsername" class="form-control" placeholder="Gebruikersnaam" required autofocus>
  70.             
  71.             <label for="inputPassword" class="sr-only">Wachtwoord</label>
  72.             <input type="password" id="inputPassword" name="password" class="form-control" placeholder="Wachtwoord" required>
  73.             
  74.             <input type="hidden" name="_csrf_token"
  75.                    value="{{ csrf_token('authenticate') }}"
  76.             >
  77.             
  78.              {#
  79.             <div class="checkbox mb-3">
  80.             <label>
  81.               <input type="checkbox" value="remember-me"> Remember me
  82.             </label>
  83.             </div>
  84.              #}
  85.             <button class="btn btn-lg btn-primary btn-block" type="submit">Inloggen</button>
  86.                         {% if error %}
  87.                 <div class="alert alert-danger mt-3">{{ error.messageKey|trans(error.messageData, 'security') }}</div>
  88.             {% endif %}
  89.             {% if app.user %}
  90.                 <div class="mt-3 alert alert-danger" role="alert">
  91.                     Je bent al ingelogd als {{ app.user.username }}, <a href="{{ path('app_logout') }}">klik hier om uit te loggen</a>
  92.                 </div>
  93.             {% endif %}
  94.             
  95.             <p class="mt-5 mb-3 text-muted">&copy; Twente PC 2020 - {{ "now"|date("Y") }}</p>
  96.         </form>
  97.     </body>
  98. {% endblock %}