redirect
This commit is contained in:
parent
9475db0347
commit
eeddecd582
1 changed files with 5 additions and 3 deletions
|
@ -86,6 +86,8 @@ actions.register(editPage)
|
||||||
def redirect_url(request, url):
|
def redirect_url(request, url):
|
||||||
if request.META['QUERY_STRING']:
|
if request.META['QUERY_STRING']:
|
||||||
url += "?" + request.META['QUERY_STRING']
|
url += "?" + request.META['QUERY_STRING']
|
||||||
response = HttpResponse()
|
|
||||||
response.write('<script>document.location.href="%s";</script>'%url)
|
if settings.CONFIG.get('sendReferrer', False):
|
||||||
return response
|
return redirect(url)
|
||||||
|
else:
|
||||||
|
return HttpResponse('<script>document.location.href=%s;</script>'%json.dumps(url))
|
||||||
|
|
Loading…
Reference in a new issue