templates/security/login.html.twig line 1

Open in your IDE?
  1. {% extends 'base.html.twig' %}
  2. {% block body_id 'login' %}
  3. {% block javascripts %}
  4.     {{ parent() }}
  5.     {{ encore_entry_script_tags('login') }}
  6. {% endblock %}
  7. {% block main %}
  8.     {% if error %}
  9.         <div class="alert alert-danger">
  10.             {{ error.messageKey|trans(error.messageData, 'security') }}
  11.         </div>
  12.     {% endif %}
  13.     <div class="row">
  14.         <div class="col-sm-9">
  15.             <div class="well">
  16.                 <form action="{{ path('security_login') }}" method="post">
  17.                     <fieldset>
  18.                         <legend><i class="fa fa-lock" aria-hidden="true"></i> {{ 'title.login'|trans }}</legend>
  19.                         <div class="form-group">
  20.                             <label for="username">{{ 'label.username'|trans }}</label>
  21.                             <input type="text" id="username" name="_username" value="{{ last_username }}" class="form-control"/>
  22.                         </div>
  23.                         <div class="form-group">
  24.                             <label for="password">{{ 'label.password'|trans }}</label>
  25.                             <input type="password" id="password" name="_password" class="form-control" />
  26.                         </div>
  27.                         <input type="hidden" name="_target_path" value="{{ app.request.get('redirect_to') }}"/>
  28.                         <input type="hidden" name="_csrf_token" value="{{ csrf_token('authenticate') }}"/>
  29.                         <button type="submit" class="btn btn-primary">
  30.                             <i class="fa fa-sign-in" aria-hidden="true"></i> {{ 'action.sign_in'|trans }}
  31.                         </button>
  32.                         <button type="submit" class="btn btn-default">
  33.                             <i class="fa fa-sign-in" aria-hidden="true"></i> {{ 'action.register'|trans }}
  34.                         </button>
  35.                     </fieldset>
  36.                 </form>
  37.             </div>
  38.         </div>
  39.     </div>
  40. {% endblock %}
  41. {% block sidebar %}
  42.     {{ parent() }}
  43.     {{ show_source_code(_self) }}
  44. {% endblock %}