[1.10.x] Fixed #27307 -- Added missing url names in sitemaps docs.
Backport of fe1aee6b98
from master
This commit is contained in:
parent
f4a79d3d0c
commit
67fd51a54f
|
@ -363,7 +363,8 @@ Here's what the relevant URLconf lines would look like for the example above::
|
|||
|
||||
urlpatterns = [
|
||||
url(r'^sitemap\.xml$', views.index, {'sitemaps': sitemaps}),
|
||||
url(r'^sitemap-(?P<section>.+)\.xml$', views.sitemap, {'sitemaps': sitemaps}),
|
||||
url(r'^sitemap-(?P<section>.+)\.xml$', views.sitemap, {'sitemaps': sitemaps},
|
||||
name='django.contrib.sitemaps.views.sitemap'),
|
||||
]
|
||||
|
||||
This will automatically generate a :file:`sitemap.xml` file that references
|
||||
|
@ -409,7 +410,7 @@ parameter to the ``sitemap`` and ``index`` views via the URLconf::
|
|||
url(r'^custom-sitemap-(?P<section>.+)\.xml$', views.sitemap, {
|
||||
'sitemaps': sitemaps,
|
||||
'template_name': 'custom_sitemap.html'
|
||||
}),
|
||||
}, name='django.contrib.sitemaps.views.sitemap'),
|
||||
]
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue