{# templates/login/index.html.twig #}
{% extends 'base.html.twig' %}
{# ... #}
{% block body %}
{% if error %}
<div>{{ error.messageKey|trans(error.messageData, 'security') }}</div>
{% endif %}
<div class="card" style="width: 18rem; margin:auto;">
<div class="card-body">
<form action="{{ path('login') }}" method="post">
<div class="mb-3">
<label for="username" class="form-label">Email:</label>
<input type="text" id="username" class="form-control" name="_username" value="{{ last_username }}" />
</div>
<div class="mb-3">
<label for="password" class="form-label">Password:</label>
<input type="password" id="password" class="form-control" name="_password" />
<input type="hidden" name="_csrf_token" value="{{ csrf_token('authenticate') }}">
</div>
{# If you want to control the URL the user is redirected to on success
<input type="hidden" name="_target_path" value="/account" /> #}
<button type="submit" class="btn btn-ing">login</button>
</form>
</div>
</div>
{% endblock %}