index.txt 4.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207
  1. ====================
  2. ``contrib`` packages
  3. ====================
  4. Django aims to follow Python's `"batteries included" philosophy`_. It ships
  5. with a variety of extra, optional tools that solve common Web-development
  6. problems.
  7. This code lives in ``django/contrib`` in the Django distribution. This document
  8. gives a rundown of the packages in ``contrib``, along with any dependencies
  9. those packages have.
  10. .. admonition:: Note
  11. For most of these add-ons -- specifically, the add-ons that include either
  12. models or template tags -- you'll need to add the package name (e.g.,
  13. ``'django.contrib.admin'``) to your ``INSTALLED_APPS`` setting and re-run
  14. ``manage.py syncdb``.
  15. .. _"batteries included" philosophy: http://docs.python.org/tutorial/stdlib.html#batteries-included
  16. .. toctree::
  17. :maxdepth: 1
  18. admin/index
  19. auth
  20. comments/index
  21. contenttypes
  22. csrf
  23. databrowse
  24. flatpages
  25. formtools/index
  26. gis/index
  27. humanize
  28. localflavor
  29. markup
  30. messages
  31. redirects
  32. sitemaps
  33. sites
  34. syndication
  35. webdesign
  36. admin
  37. =====
  38. The automatic Django administrative interface. For more information, see
  39. :doc:`Tutorial 2 </intro/tutorial02>` and the
  40. :doc:`admin documentation </ref/contrib/admin/index>`.
  41. Requires the auth_ and contenttypes_ contrib packages to be installed.
  42. auth
  43. ====
  44. Django's authentication framework.
  45. See :doc:`/topics/auth`.
  46. comments
  47. ========
  48. .. versionchanged:: 1.0
  49. The comments application has been rewriten. See :doc:`/ref/contrib/comments/upgrade`
  50. for information on howto upgrade.
  51. A simple yet flexible comments system. See :doc:`/ref/contrib/comments/index`.
  52. contenttypes
  53. ============
  54. A light framework for hooking into "types" of content, where each installed
  55. Django model is a separate content type.
  56. See the :doc:`contenttypes documentation </ref/contrib/contenttypes>`.
  57. csrf
  58. ====
  59. A middleware for preventing Cross Site Request Forgeries
  60. See the :doc:`csrf documentation </ref/contrib/csrf>`.
  61. flatpages
  62. =========
  63. A framework for managing simple "flat" HTML content in a database.
  64. See the :doc:`flatpages documentation </ref/contrib/flatpages>`.
  65. Requires the sites_ contrib package to be installed as well.
  66. formtools
  67. =========
  68. A set of high-level abstractions for Django forms (django.forms).
  69. django.contrib.formtools.preview
  70. --------------------------------
  71. An abstraction of the following workflow:
  72. "Display an HTML form, force a preview, then do something with the submission."
  73. See the :doc:`form preview documentation </ref/contrib/formtools/form-preview>`.
  74. django.contrib.formtools.wizard
  75. --------------------------------
  76. Splits forms across multiple Web pages.
  77. See the :doc:`form wizard documentation </ref/contrib/formtools/form-wizard>`.
  78. gis
  79. ====
  80. A world-class geospatial framework built on top of Django, that enables
  81. storage, manipulation and display of spatial data.
  82. See the :doc:`/ref/contrib/gis/index` documentation for more.
  83. humanize
  84. ========
  85. A set of Django template filters useful for adding a "human touch" to data.
  86. See the :doc:`humanize documentation </ref/contrib/humanize>`.
  87. localflavor
  88. ===========
  89. A collection of various Django snippets that are useful only for a particular
  90. country or culture. For example, ``django.contrib.localflavor.us.forms``
  91. contains a ``USZipCodeField`` that you can use to validate U.S. zip codes.
  92. See the :doc:`localflavor documentation </ref/contrib/localflavor>`.
  93. markup
  94. ======
  95. A collection of template filters that implement common markup languages
  96. See the :doc:`markup documentation </ref/contrib/markup>`.
  97. messages
  98. ========
  99. .. versionchanged:: 1.2
  100. The messages framework was added.
  101. A framework for storing and retrieving temporary cookie- or session-based
  102. messages
  103. See the :doc:`messages documentation </ref/contrib/messages>`.
  104. redirects
  105. =========
  106. A framework for managing redirects.
  107. See the :doc:`redirects documentation </ref/contrib/redirects>`.
  108. sessions
  109. ========
  110. A framework for storing data in anonymous sessions.
  111. See the :doc:`sessions documentation </topics/http/sessions>`.
  112. sites
  113. =====
  114. A light framework that lets you operate multiple Web sites off of the same
  115. database and Django installation. It gives you hooks for associating objects to
  116. one or more sites.
  117. See the :doc:`sites documentation </ref/contrib/sites>`.
  118. sitemaps
  119. ========
  120. A framework for generating Google sitemap XML files.
  121. See the :doc:`sitemaps documentation </ref/contrib/sitemaps>`.
  122. syndication
  123. ===========
  124. A framework for generating syndication feeds, in RSS and Atom, quite easily.
  125. See the :doc:`syndication documentation </ref/contrib/syndication>`.
  126. webdesign
  127. =========
  128. Helpers and utilities targeted primarily at Web *designers* rather than
  129. Web *developers*.
  130. See the :doc:`Web design helpers documentation </ref/contrib/webdesign>`.
  131. Other add-ons
  132. =============
  133. If you have an idea for functionality to include in ``contrib``, let us know!
  134. Code it up, and post it to the `django-users mailing list`_.
  135. .. _django-users mailing list: http://groups.google.com/group/django-users