~ubuntu-branches/ubuntu/quantal/python-django/quantal-security

« back to all changes in this revision

Viewing changes to docs/ref/contrib/sitemaps.txt

  • Committer: Bazaar Package Importer
  • Author(s): Jamie Strandboge
  • Date: 2010-10-12 11:34:35 UTC
  • mfrom: (1.1.12 upstream) (29.1.1 maverick-security)
  • Revision ID: james.westby@ubuntu.com-20101012113435-yy57c8tx6g9anf3e
Tags: 1.2.3-1ubuntu0.1
* SECURITY UPDATE: XSS in CSRF protections. New upstream release
  - CVE-2010-3082
* debian/patches/01_disable_url_verify_regression_tests.diff:
  - updated to disable another test that fails without internet connection
  - patch based on work by Kai Kasurinen and Krzysztof Klimonda
* debian/control: don't Build-Depends on locales-all, which doesn't exist
  in maverick

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
.. _ref-contrib-sitemaps:
2
 
 
3
1
=====================
4
2
The sitemap framework
5
3
=====================
23
21
The Django sitemap framework automates the creation of this XML file by letting
24
22
you express this information in Python code.
25
23
 
26
 
It works much like Django's :ref:`syndication framework
27
 
<ref-contrib-syndication>`. To create a sitemap, just write a
 
24
It works much like Django's :doc:`syndication framework
 
25
</ref/contrib/syndication>`. To create a sitemap, just write a
28
26
:class:`~django.contrib.sitemaps.Sitemap` class and point to it in your
29
 
:ref:`URLconf <topics-http-urls>`.
 
27
:doc:`URLconf </topics/http/urls>`.
30
28
 
31
29
Installation
32
30
============
52
50
==============
53
51
 
54
52
To activate sitemap generation on your Django site, add this line to your
55
 
:ref:`URLconf <topics-http-urls>`::
 
53
:doc:`URLconf </topics/http/urls>`::
56
54
 
57
55
   (r'^sitemap\.xml$', 'django.contrib.sitemaps.views.sitemap', {'sitemaps': sitemaps})
58
56
 
227
225
.. class:: GenericSitemap
228
226
 
229
227
    The :class:`django.contrib.sitemaps.GenericSitemap` class works with any
230
 
    :ref:`generic views <ref-generic-views>` you already have.
 
228
    :doc:`generic views </ref/generic-views>` you already have.
231
229
    To use it, create an instance, passing in the same :data:`info_dict` you pass to
232
230
    the generic views. The only requirement is that the dictionary have a
233
231
    :data:`queryset` entry. It may also have a :data:`date_field` entry that specifies a
240
238
Example
241
239
-------
242
240
 
243
 
Here's an example of a :ref:`URLconf <topics-http-urls>` using both::
 
241
Here's an example of a :doc:`URLconf </topics/http/urls>` using both::
244
242
 
245
243
    from django.conf.urls.defaults import *
246
244
    from django.contrib.sitemaps import FlatPageSitemap, GenericSitemap