Force page reload with anchors
Force page to reload even when the location contains anchors, while using "web2py-redirect-location". Otherwise, when the location is the same and the url has an anchor it won't redirect.
This commit is contained in:
@@ -284,6 +284,7 @@
|
||||
var redirect = xhr.getResponseHeader('web2py-redirect-location');
|
||||
if (redirect !== null) {
|
||||
window.location = redirect;
|
||||
window.location.reload(); // Force reload even with anchors
|
||||
}
|
||||
/* run this here only if this Ajax request is NOT for a web2py component. */
|
||||
if (xhr.getResponseHeader('web2py-component-content') === null) {
|
||||
|
||||
Reference in New Issue
Block a user