Instantly share code, notes, and snippets.

Embed
What would you like to do?
Symfony - Création d'un espace sécurisé (Views)
{% extends 'base.html.twig' %}
{% block body %}
<h1>Connexion</h1>
{% if error %}
<div class="alert alert-danger">{{ error.message }}</div>
{% endif %}
<form method="post" action="{{ path('login_check') }}" class="form-horizontal col-md-6 col-md-offset-2">
<div class="form-group">
<label class="control-label col-sm-4" id="inputUsername">Nom d'utilisateur</label>
<div class="col-sm-8">
<input type="text" id="inputUsername" name="_username" value="{{ last_username }}" class="form-control" />
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-4" for="inputPassword">Mot de passe</label>
<div class="col-sm-8">
<input type="password" id="inputPassword" name="_password" class="form-control" />
</div>
</div>
<div class="form-group">
<div class="col-sm-8 col-sm-offset-4">
<button class="btn btn-default">
<i class="glyphicon glyphicon-lock"></i> Se connecter
</button>
</div>
</div>
</form>
{% endblock %}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment