Created
January 14, 2014 18:30
-
-
Save marydn/8423187 to your computer and use it in GitHub Desktop.
Render all flash messages from Symfony in Twig.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{% for label, flashes in app.session.flashbag.all %} | |
{% for flash in flashes %} | |
<div class="alert alert-{{ label }}"> | |
{{ flash }} | |
</div> | |
{% endfor %} | |
{% endfor %} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment