_form.html 645 Bytes
Newer Older
Patrick Kimber's avatar
Patrick Kimber committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
<form action="" method="post" class="pure-form pure-form-stacked">
  {% csrf_token %}
  {{ form.non_field_errors }}
  <fieldset>
    {% for field in form %}
      <div class="pure-control-group">
        {{ field.label_tag }}
        {% for error in field.errors %}
          <aside class="pure-help-inline">{{ error }}</aside>
        {% endfor %}
        {{ field }}
      </div>
    {% endfor %}
    <div class="pure-controls">
      <p>
        <input type="submit" value="Submit" class="pure-button pure-button-primary" />
      </p>
    </div>
  </fieldset>
  {% for hidden in form.hidden_fields %}
    {{ hidden }}
  {% endfor %}
</form>