Advertisement
Guest User

Untitled

a guest
Aug 27th, 2015
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 1.11 KB | None | 0 0
  1. {% extends "base/theme.html" %}
  2. {% load widget_tweaks %}
  3. {% block main_content %}
  4.     <div class="header-buffer">
  5.     </div>
  6.     <section id="services">
  7.         <div class="container">
  8.             <div class="row">
  9.                 {% if form %}
  10.                     <div class="col-md-8 col-md-offset-2">
  11.                         <form action="" method="post" enctype="multipart/form-data">
  12.                             {% csrf_token %}
  13.                             {{ form.media }}
  14.                             {% for field in form %}
  15.                                 <div class="form-group warning">
  16.                                     <label for="exampleInputFile">{{ field.label }}</label>
  17.                                     {{ field|add_class:"form-control"}}
  18.                                     {% if field.help_text %}
  19.                                         <p class="help-block">{{ field.help_text }}</p>
  20.                                     {% endif %}
  21.                                 </div>
  22.                                 {% if field.errors %}
  23.                                     {% for error in field.errors %}
  24.                                         <div class="alert alert-danger" id="error_{{ field.name }}">{{ error|escape }}</div>
  25.                                     {% endfor %}
  26.                                 {% endif %}
  27.                             {% endfor %}
  28.                             <input type="submit" class="btn btn-success" role="button" value="{{ verb|default:"Submit" }}" />
  29.                         </form>
  30.                     </div>
  31.                 {% endif %}
  32.             </div>
  33.         </div>
  34.     </section>
  35. {% endblock %}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement