-
-
Save leevigraham/f1bd326499eb35926df6 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
{% macro form_fields(form) %} | |
{% for field in form %} | |
{% if field.vars.block_prefixes[0] != 'button' %} | |
{{ form_row(field) }} | |
{% endif %} | |
{% endfor %} | |
{% endmacro %} | |
{% import _self as macros %} | |
<form class="form-horizontal" method="post" action="{{ path('foo_bar') }}" {{ form_enctype(form) }}> | |
{{ macros.form_fields(form) }} | |
<div class="form-actions"> | |
<p> | |
{{ form_widget(form.submit) }} | |
</p> | |
</div> | |
{{ form_rest(form) }} | |
</form> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment