templates/Front/index/index.html.twig line 1

Open in your IDE?
  1. {% extends 'base.html.twig' %}
  2. {% from 'Front/macros.html.twig' import blockCompetition %}
  3. {% block title %}Africa TKD Referee{% endblock %}
  4. {% block body %}
  5. <div class="example-wrapper">
  6.     {% if not app.user %}
  7.         <div class="p-2 bg-light border">
  8.             <form class="row" method="post">
  9.                 {% if error %}
  10.                     <div class="alert alert-danger">{{ error.messageKey|trans(error.messageData, 'security') }}</div>
  11.                 {% endif %}
  12.                 <h1 class="h3 mb-3 font-weight-normal">Please sign in</h1>
  13.                 <div class="col-lg-5 col-sm-12 mb-3">
  14.                     <label for="inputEmail" class="visually-hidden">Email</label>
  15.                     <input type="email" value="{{ last_username }}" name="email" class="form-control" id="inputEmail" placeholder="email@example.com" autocomplete="email" required autofocus>
  16.                 </div>
  17.                 <div class="col-lg-5 col-sm-12 mb-3">
  18.                     <label for="inputPassword" class="visually-hidden">Password</label>
  19.                     <input type="password" name="password" id="inputPassword" class="form-control" placeholder="Password" autocomplete="current-password" required>
  20.                 </div>
  21.                 <input type="hidden" name="_csrf_token"
  22.                     value="{{ csrf_token('authenticate') }}"
  23.                 >
  24.                 
  25.                 {# <input type="hidden" name="reponsecaptcha" id="recaptcha"> #}
  26.                 <div class="col">
  27.                     <button type="submit" class="btn btn-primary col-lg-12 col-sm-12 mb-3">Sign in</button>
  28.                 </div>
  29.                 <div class="row">
  30.                     <div class="col">
  31.                         <a href="{{ path('app_forgot_password_request') }}" class="btn btn-link">Forgot your password ?</a>
  32.                     </div>
  33.                     <div class="col">
  34.                         <a href="{{ path('app_register') }}" class="btn btn-link float-end text-success">No account ? Create one here</a>
  35.                     </div>
  36.                 </div>
  37.             </form>
  38.             {# <script src="https://www.google.com/recaptcha/api.js?render=6Lf_McYqAAAAAPCyFezgpaRprnf-ji6KiXkK7ckW"></script>
  39.             <script>
  40.                 grecaptcha.ready(function () {
  41.                     grecaptcha.execute('6Lf_McYqAAAAAPCyFezgpaRprnf-ji6KiXkK7ckW', { action: 'contact' }).then(function (token) {
  42.                         var recaptchaResponse = document.getElementById('recaptcha');
  43.                         recaptchaResponse.value = token;
  44.                     });
  45.                 });
  46.             </script> #}
  47.         </div> 
  48.     {% else %}
  49.         {% if not app.user.isverified %}
  50.             <div class="alert alert-dismissible alert-danger">
  51.                 <button type="button" class="btn-close" data-bs-dismiss="alert"></button>
  52.                 <strong>Your email address is not yet verified</strong>
  53.                 an email is sent to you, please validate your email address
  54.                 if expired <a href="{{ path('emailverify') }}" class="alert-link">you can resend </a>
  55.             </div>
  56.         {% endif %}
  57.     {% endif %}
  58.     {% for competition in competitions %}
  59.             {{ blockCompetition(competition) }}
  60.     {% endfor %}
  61. </div>
  62. {% endblock %}