Connexion par formulaire
This commit is contained in:
22
templates/login/index.html.twig
Normal file
22
templates/login/index.html.twig
Normal file
@@ -0,0 +1,22 @@
|
||||
{% extends 'base.html.twig' %}
|
||||
|
||||
{% block title %}Hello LoginController!{% endblock %}
|
||||
|
||||
{% block body %}
|
||||
{% if error %}
|
||||
<div>{{ error.messageKey|trans(error.messageData, 'security') }}</div>
|
||||
{% endif %}
|
||||
|
||||
<form action="{{ path('app_login') }}" method="post">
|
||||
<label for="username">Email:</label>
|
||||
<input type="text" id="username" name="_username" value="{{ last_username }}">
|
||||
|
||||
<label for="password">Password:</label>
|
||||
<input type="password" id="password" name="_password">
|
||||
|
||||
{# 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">login</button>
|
||||
</form>
|
||||
{% endblock %}
|
Reference in New Issue
Block a user