templates/security/connexion.html.twig line 1

Open in your IDE?
  1. {% extends "base.html.twig" %}
  2. {% block title %}{{ parent() }}    | Connexion{% endblock %}
  3. {% block stylesheets %}<link rel="stylesheet" href="{{ asset('css/connexion.css') }}">{% endblock %}
  4. {% block h1 %}Connexion{% endblock %}
  5. {% block content %}
  6.         <div class="wrapper col-12 d-flex flex-lg-row flex-column ">
  7.             <div class="col-lg-7 col-12 my-auto">
  8.                 <img id="slideShow" class="d-block w-50 mx-auto" src="" alt="">
  9.             </div>
  10.             <div class=" col-lg-3 col-6 mb-5 mx-auto d-flex flex-column justify-content-center">
  11.                 <form action="{{ path('connexion')}}" method="post" class='col-12 mx-auto text-center mt-5'>
  12.                     <div class="col-12 form-group mx-auto mt-2">
  13.                         <input type="text" id="inputEmail" class="form-control " name="_username" placeholder="Email">
  14.                     </div>
  15.                     <div class="col-12 form-group mx-auto my-3">
  16.                         <div class='input-group'>
  17.                             <input type="password" id="inputPassword" class="form-control" name="_password" data-toggle="password" placeholder="Mot de passe">
  18.                             <span class="input-group-text bg-white">
  19.                                 <i class="fa fa-eye"></i>
  20.                             </span>
  21.                         </div>
  22.                     </div>
  23.                      <input type="hidden" name="_csrf_token" value="{{ csrf_token('authenticate') }}">
  24.                     <a class='reset-password-link' href="{{ path('app_forgot_password_request') }}">Mot de passe oubliĆ© ?</a>
  25.                     <input type="submit" value="Connexion" class="col-12 btn btn-dark my-3">
  26.                 </form>
  27.             </div>
  28.         </div>
  29.     <textarea name="" hidden id="photos" cols="30" rows="10">{{photos}}</textarea>
  30. {% endblock %}
  31. {% block javascripts %}
  32.     <script>
  33.         var photos = JSON.parse(document.querySelector('#photos').innerHTML)
  34. nbphotos = photos.length
  35. function photoShow() {
  36. let position = Math.trunc(Math.random() * (nbphotos))
  37. let nomPhoto = photos[position]
  38. let cheminPhoto = "{{ asset('img/photoProduitUpload/') }}"
  39. document.getElementById('slideShow').setAttribute('src', cheminPhoto + nomPhoto)
  40. }
  41. photoShow()
  42. setInterval("photoShow()", 5000);
  43.     </script>
  44.     <script  src="{{ asset("js/bootstrap-show-password.min.js") }}"></script>
  45. {% endblock %}