diff options
author | Evgeny Fadeev <evgeny.fadeev@gmail.com> | 2009-12-09 19:57:49 -0500 |
---|---|---|
committer | Evgeny Fadeev <evgeny.fadeev@gmail.com> | 2009-12-09 20:02:36 -0500 |
commit | fdac57838a27f3837b0ef187a9a3f86f293d29b1 (patch) | |
tree | ba9975b0e22fa02c97608f030395b4c26c31e972 /forum/sitemap.py | |
parent | 4be0491e6adef6bf5817545ec9e050555066352f (diff) | |
download | askbot-fdac57838a27f3837b0ef187a9a3f86f293d29b1.tar.gz askbot-fdac57838a27f3837b0ef187a9a3f86f293d29b1.tar.bz2 askbot-fdac57838a27f3837b0ef187a9a3f86f293d29b1.zip |
added sitemap at /sitemap.xml and fixed per tag subscription (hopefully)
Diffstat (limited to 'forum/sitemap.py')
-rw-r--r-- | forum/sitemap.py | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/forum/sitemap.py b/forum/sitemap.py new file mode 100644 index 00000000..dc97a009 --- /dev/null +++ b/forum/sitemap.py @@ -0,0 +1,11 @@ +from django.contrib.sitemaps import Sitemap +from forum.models import Question + +class QuestionsSitemap(Sitemap): + changefreq = 'daily' + priority = 0.5 + def items(self): + return Question.objects.exclude(deleted=True) + + def lastmod(self, obj): + return obj.last_activity_at |