diff --git a/CHANGES.rst b/CHANGES.rst index 6a49ecbd..36954a50 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -7,6 +7,8 @@ Video/streaming content replay and buffering improvements! pywb 0.6.6 changelist ~~~~~~~~~~~~~~~~~~~~~ +* JS client side improvements: check for double-inits, preserve anchor in wb.js top location redirect + * JS Rewriters: add mixins for link + location (default), link only, location only rewriting by setting ``js_rewrite_location`` to ``all``, ``urls``, ``location``, respectively. (New: location only rewriting does not change JS urls) @@ -34,7 +36,6 @@ pywb 0.6.5 changelist * cdx-indexer: Detect non-gzip chunk encoded .warc.gz/arc.gz archive files and show a meaningful error message explaining how to fix issue (uncompress and possibly use warctools warc2warc to recompress) ->>>>>>> develop pywb 0.6.4 changelist diff --git a/pywb/static/wb.js b/pywb/static/wb.js index 1974c59f..ea14c9fa 100644 --- a/pywb/static/wb.js +++ b/pywb/static/wb.js @@ -129,11 +129,13 @@ this.load = function() { if ((window.self == window.top) && wbinfo) { + var hash = window.location.hash; + var loc = window.location.href.replace(window.location.hash, ""); if (wbinfo.top_url && (loc != wbinfo.top_url) && wbinfo.mod != "bn_") { // Auto-redirect to top frame - window.location.replace(wbinfo.top_url); + window.location.replace(wbinfo.top_url + hash); } else { // Init Banner (no frame or top frame) add_event("readystatechange", init_banner, document);