#10909: Django Sitemaps Framework does not allow the use of the Domain Settings Site --------------------------+------------------------------------------------- Reporter: qingfeng | Owner: nobody Status: new | Milestone: Component: Contrib apps | Version: 1.0 Keywords: sitemaps | Stage: Unreviewed Has_patch: 1 | --------------------------+------------------------------------------------- Django Sitemaps Framework does not allow the use of the Domain Settings Site
In settings.py add a variable DOMAIN {{{ DOMAIN = 'www.example.com' }}} example: location of the place, do not rely on the domain name Site Settings {{{ class KhufuSitemap(Sitemap): changefreq = "never" priority = 0.5 def items(self): return [obj,obj,obj] def location(self,obj): return "/v/%s/" % obj["kid"] def lastmod(self, obj): return datetime.strptime(obj["savedate"],'%Y-%m-%d') }}} -- Ticket URL: <http://code.djangoproject.com/ticket/10909> Django <http://code.djangoproject.com/> The Web framework for perfectionists with deadlines. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django updates" group. To post to this group, send email to django-updates@googlegroups.com To unsubscribe from this group, send email to django-updates+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-updates?hl=en -~----------~----~----~----~------~----~------~--~---