Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Now uses history.replaceState - if present.

  • Loading branch information...
commit 1f1e5bccf19d31e2029f0794de9b9fb16c3e270f 1 parent 328d444
@mworrell mworrell authored
Showing with 6 additions and 1 deletion.
  1. +6 −1 modules/mod_base/lib/js/modules/scrollpaluza.js
View
7 modules/mod_base/lib/js/modules/scrollpaluza.js
@@ -40,7 +40,12 @@
}
}
if (best) {
- document.location.hash = '#'+best.id;
+ if (window.history.replaceState) {
+ var ps = window.location.href.split('#');
+ window.history.replaceState(null, this.title, ps[0]+"#"+ best.id);
+ } else {
+ document.location.hash = '#'+best.id;
+ }
}
waiting=false;
}, 150);
Please sign in to comment.
Something went wrong with that request. Please try again.