diff options
author | Dan McGee <dan@archlinux.org> | 2014-11-08 16:31:38 -0600 |
---|---|---|
committer | Dan McGee <dan@archlinux.org> | 2014-11-08 16:31:38 -0600 |
commit | 96a7614285325b693434f3fd011238000d75926d (patch) | |
tree | 243fab620a9fa57cd93c2412bde1f7190373caf0 /urls.py | |
parent | 4c5b478543184ea395e0e692d3bcf666fb7513ad (diff) |
Add a news-specific sitemap
This follows the spec at
https://support.google.com/news/publisher/answer/74288?hl=en#tagdefinitions
Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'urls.py')
-rw-r--r-- | urls.py | 9 |
1 files changed, 8 insertions, 1 deletions
@@ -18,6 +18,8 @@ our_sitemaps = { 'releases': sitemaps.ReleasesSitemap, } +news_sitemaps = { 'news': sitemaps.RecentNewsSitemap } + urlpatterns = [] # Public pages @@ -81,7 +83,12 @@ urlpatterns += patterns('', {'sitemaps': our_sitemaps, 'sitemap_url_name': 'sitemaps'}), (r'^sitemap-(?P<section>.+)\.xml$', cache_page(1831)(sitemap_views.sitemap), - {'sitemaps': our_sitemaps, 'template_name': 'sitemaps/sitemap.xml.jinja'}, 'sitemaps'), + {'sitemaps': our_sitemaps, 'template_name': 'sitemaps/sitemap.xml.jinja'}, + 'sitemaps'), + (r'^news-sitemap\.xml$', + cache_page(1831)(sitemap_views.sitemap), + {'sitemaps': news_sitemaps, 'template_name': 'sitemaps/news_sitemap.xml.jinja'}, + 'news-sitemap'), ) # Authentication / Admin |