mirror of
https://github.com/django/django.git
synced 2025-10-31 09:41:08 +00:00
Fixed #25916 -- Added lastmod support to sitemap index view.
Co-authored-by: Matthew Downey <matthew.downey@webit.com.au>
This commit is contained in:
committed by
Carlton Gibson
parent
2ce03a2bac
commit
480191244d
@@ -0,0 +1,14 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!-- This is a customised template -->
|
||||
<sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
|
||||
{% spaceless %}
|
||||
{% for site in sitemaps %}
|
||||
<sitemap>
|
||||
<loc>{{ site.location }}</loc>
|
||||
{% if site.last_mod %}
|
||||
<lastmod>{{ site.last_mod|date:"c" }}</lastmod>
|
||||
{% endif %}
|
||||
</sitemap>
|
||||
{% endfor %}
|
||||
{% endspaceless %}
|
||||
</sitemapindex>
|
||||
Reference in New Issue
Block a user