Changeset 49
- Timestamp:
- 10/10/06 12:06:30 (2 years ago)
- Files:
-
- 1 modified
-
django/trunk/middleware/sslmiddleware.py (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
django/trunk/middleware/sslmiddleware.py
r48 r49 22 22 from django.conf import settings 23 23 from django.http import HttpResponseRedirect 24 from django.http import get_host 24 25 25 26 class SSLMiddleware: … … 43 44 def _redirect(self, request, protocol): 44 45 newurl = "%s://%s%s" % \ 45 (protocol, request.META['HTTP_HOST'], request.path)46 (protocol, get_host(request), request.path) 46 47 if request.GET: 47 48 newurl += '?' + request.GET.urlencode()