mirror of
https://github.com/btcpayserver/btcpayserver.git
synced 2025-03-04 09:58:13 +01:00
13 lines
434 B
JavaScript
13 lines
434 B
JavaScript
|
var urlParams;
|
||
|
(window.onpopstate = function () {
|
||
|
var match,
|
||
|
pl = /\+/g, // Regex for replacing addition symbol with a space
|
||
|
search = /([^&=]+)=?([^&]*)/g,
|
||
|
decode = function (s) { return decodeURIComponent(s.replace(pl, " ")); },
|
||
|
query = window.location.search.substring(1);
|
||
|
|
||
|
urlParams = {};
|
||
|
while (match = search.exec(query))
|
||
|
urlParams[decode(match[1])] = decode(match[2]);
|
||
|
})();
|