* the requested query parameters. It may also be omitted completely for a
* link without query parameters.
*/
-const pagenames = ['search', 'reverse', 'details', 'deletable', 'polygons', 'about'];
+const pagenames = ['search', 'reverse', 'details', 'deletable', 'polygons', 'status', 'about'];
export function refresh_page(pagename, params) {
if (typeof pagename === 'undefined') {
if (param_str) {
param_str = '?' + param_str;
}
- window.history.pushState([], '', pagename + '.html' + param_str);
+ let new_url = pagename + '.html' + param_str;
+
+ if (window.location.protocol.match(/^http/)) {
+ window.history.pushState([], '', new_url);
+ } else {
+ window.location.href = new_url;
+ }
}
page.set({ tab: pagename, params: params });