[FIX] redirect_with_hash firefox bug
bzr revid: fme@openerp.com-20140121160158-qsy28zty51wg7ip4
This commit is contained in:
parent
646a7de17a
commit
b5118e606e
|
@ -67,6 +67,8 @@ def redirect_with_hash(url, code=303):
|
||||||
# redirect. And even if IE10 pretends to support it, it still fails
|
# redirect. And even if IE10 pretends to support it, it still fails
|
||||||
# inexplicably in case of multiple redirects (and we do have some).
|
# inexplicably in case of multiple redirects (and we do have some).
|
||||||
# See extensive test page at http://greenbytes.de/tech/tc/httpredirects/
|
# See extensive test page at http://greenbytes.de/tech/tc/httpredirects/
|
||||||
|
if request.httprequest.user_agent.browser in ('firefox',):
|
||||||
|
return werkzeug.utils.redirect(url, code)
|
||||||
return "<html><head><script>window.location = '%s' + location.hash;</script></head></html>" % url
|
return "<html><head><script>window.location = '%s' + location.hash;</script></head></html>" % url
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue