Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- {% extends 'base.html.twig' %}
- {% block title %}Hello!{% endblock %}
- {% block body %}
- <style>
- .example-wrapper { margin: 1em auto; max-width: 800px; width: 95%; font: 18px/1.5 sans-serif; }
- .example-wrapper code { background: #F5F5F5; padding: 2px 6px; }
- .error {color: red}
- </style>
- <div class="example-wrapper">
- <h1>Login page!</h1>
- {% if app.user %}
- <a href="{{ path('logout') }}">logout</a>
- {% else %}
- {% if error %}
- <span class="error">{{ error.messageKey }}</span>
- {% endif %}
- <form action="{{ path('login') }}" method="post">
- <input type="text" name="_username" value="{{ last_username }}" placeholder="Username here ...">
- <input type="password" name="_password">
- <button type="submit">login</button>
- </form>
- {% endif %}
- </div>
- {% endblock %}
Add Comment
Please, Sign In to add comment