Hello,

this is my first post here and I hope this is the right place for
discussing ideas django-features before reporting a ticket.

I encountered a problem related to the URL-building using sitemaps and
the site-framework. I noticed there is no function for getting the
"real" URL from the domain.

The docs say: http://%s%s' % (Site.objects.get_current().domain,
obj.get_absolute_url())
https://docs.djangoproject.com/en/1.3/ref/contrib/sites/#getting-the-current-domain-for-full-urls

The sitemap-framework does it the same way:
sitemaps/__init__.py:34:ping_google(): url = "http://%s%s"; %
(current_site.domain, sitemap_url)
sitemaps/__init__.py:76:get_urls(): loc = "http://%s%s"; %
(site.domain, self.__get('location', item))

In my case my site is only accessible via https and http gets
redirected to https. That's the point where google complains that the
sitemap doesn't contain final URLs, but redirects.

Well, I may be missing something, but in my opinion the hard-coded
http should get improved. I'm no framework developer, but I can
imagine to put the preferred protocol into the site model-object in
addition to the domain and the name.

Greets
momo

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers" group.
To post to this group, send email to django-developers@googlegroups.com.
To unsubscribe from this group, send email to 
django-developers+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-developers?hl=en.

Reply via email to