contrib packages¶
Django aims to follow Python’s “batteries included” philosophy. It ships with a variety of extra, optional tools that solve common Web-development problems.
This code lives in django/contrib in the Django distribution. This document gives a rundown of the packages in contrib, along with any dependencies those packages have.
Note
For most of these add-ons – specifically, the add-ons that include either models or template tags – you’ll need to add the package name (e.g., 'django.contrib.admin') to your INSTALLED_APPS setting and re-run manage.py syncdb.
- The Django admin site
- django.contrib.auth
- User
- Anonymous users
- Permission
- Group
- Login and logout signals
- Authentication backends
- Django’s comments framework
- The contenttypes framework
- Cross Site Request Forgery protection
- Databrowse
- The flatpages app
- django.contrib.formtools
- GeoDjango
- django.contrib.humanize
- The “local flavor” add-ons
- django.contrib.markup
- The messages framework
- The redirects app
- The sitemap framework
- The “sites” framework
- The staticfiles app
- The syndication feed framework
- django.contrib.webdesign
admin¶
The automatic Django administrative interface. For more information, see Tutorial 2 and the admin documentation.
Requires the auth and contenttypes contrib packages to be installed.
comments¶
A simple yet flexible comments system. See Django’s comments framework.
contenttypes¶
A light framework for hooking into “types” of content, where each installed Django model is a separate content type.
See the contenttypes documentation.
flatpages¶
A framework for managing simple “flat” HTML content in a database.
See the flatpages documentation.
Requires the sites contrib package to be installed as well.
formtools¶
A set of high-level abstractions for Django forms (django.forms).
django.contrib.formtools.preview¶
An abstraction of the following workflow:
“Display an HTML form, force a preview, then do something with the submission.”
See the form preview documentation.
django.contrib.formtools.wizard¶
Splits forms across multiple Web pages.
See the form wizard documentation.
gis¶
A world-class geospatial framework built on top of Django, that enables storage, manipulation and display of spatial data.
See the GeoDjango documentation for more.
humanize¶
A set of Django template filters useful for adding a “human touch” to data.
See the humanize documentation.
localflavor¶
A collection of various Django snippets that are useful only for a particular country or culture. For example, django.contrib.localflavor.us.forms contains a USZipCodeField that you can use to validate U.S. zip codes.
See the localflavor documentation.
markup¶
A collection of template filters that implement common markup languages
See the markup documentation.
messages¶
A framework for storing and retrieving temporary cookie- or session-based messages
See the messages documentation.
sites¶
A light framework that lets you operate multiple Web sites off of the same database and Django installation. It gives you hooks for associating objects to one or more sites.
See the sites documentation.
syndication¶
A framework for generating syndication feeds, in RSS and Atom, quite easily.
See the syndication documentation.
webdesign¶
Helpers and utilities targeted primarily at Web designers rather than Web developers.
See the Web design helpers documentation.
Other add-ons¶
If you have an idea for functionality to include in contrib, let us know! Code it up, and post it to the django-users mailing list.