Now I’m coding simple design-tracking system. Almost looks like a blog service.
I use Flask as web app flame work. But I’m not good at web design. It’s difficult for me to make form template.
There are some extensions about Flask. And I found that using Flask-Bootstrap( Bootstrap ) make easy to beautiful layout.
Key point was that, wrap form tag with <div class=”form-group tag”> and set “form-control” class in form.field.
{% extends "base.html" %} {% block content %} <div class='content container'> <div class="row"> <div class="col-md-12"> <p>Project Code {{ pj }}</p> <p> DESIGN TRACKER</p> </div> </div> <div class="row"> <div class="col-md-4"> <form role="form" action="/hypothesis/create/", method='post'> <div class="form-group"> {% for field in form if field.id != "csrf_token" %} {{ field.label }}{{ field(class="form-control") }} {% endfor %} </div> </form> </div>
This code will make following view..
Just tips for me.