Django bootstrap form
=====================
.. image:: https://badge.fury.io/py/django-bootstrap-form.png
:alt: PyPI version
:target: https://pypi.python.org/pypi/django-bootstrap-form
.. image:: https://travis-ci.org/tzangms/django-bootstrap-form.png?branch=master
:target: https://travis-ci.org/tzangms/django-bootstrap-form
.. image:: https://coveralls.io/repos/tzangms/django-bootstrap-form/badge.png?branch=master
:target: https://coveralls.io/r/tzangms/django-bootstrap-form?branch=master
Twitter Bootstrap for Django Form.
A simple Django template tag to work with `Bootstrap <http://getbootstrap.com/>`_
Usage
======
Add "bootstrapform" to your INSTALLED_APPS.
At the top of your template load in our template tags::
{% load bootstrap %}
Then to render your form::
<form role="form">
<legend>Form Title</legend>
{% csrf_token %}
{{ form|bootstrap }}
<div class="form-group">
<button type="submit" class="btn btn-primary">Submit</button>
</div>
</form>
You can also set class="form-vertical" on the form element.
To use class="form-inline" on the form element, also change the "|boostrap" template tag to "|bootstrap_inline".
It is also possible to create a horizontal form. The form class and template tag are both changed, and you will also need slightly different CSS around the submit button::
<form class="form-horizontal">
<legend>Form Title</legend>
{% csrf_token %}
{{ form|bootstrap_horizontal }}
<div class="form-group">
<div class="col-sm-10 col-sm-offset-2">
<button type="submit" class="btn btn-primary">Submit</button>
</div>
</div>
</form>
Demo
=====
Checkout this `Demo site <http://django-bootstrap-form.herokuapp.com/>`_ to see it in action.
Metadata
Release files for django-bootstrap-form-tkliuxing 3.2.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| django-bootstrap-form-tkliuxing-3.2.1.tar.gz | 4.3 kB | Without provenance | Details for django-bootstrap-form-tkliuxing-3.2.1.tar.gz |
Release files / django-bootstrap-form-tkliuxing-3.2.1.tar.gz
| Download URL | django-bootstrap-form-tkliuxing-3.2.1.tar.gz |
|---|---|
| Size | 4.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
fb4a4e15a79c7e10124c12112c1486974aabcc1749180adb75f663c91f06b8b7
|
|
BLAKE2b-256 checksum How to use checksums |
08c5c912b0de198d33e3b27e20bb57b984308fe5d60155613796e348722c61e1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for django-bootstrap-form-tkliuxing 3.2.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.