Files
help365/platform/hmcontextids.js
koziavin 00717a92fb
All checks were successful
Deploy Static Site / deploy (push) Successful in 6m6s
update
2025-05-29 16:42:45 +04:00

15 lines
479 B
JavaScript

var hmContextIds = new Array();
function hmGetContextId(query) {
var urlParams;
var match,
pl = /\+/g,
search = /([^&=]+)=?([^&]*)/g,
decode = function (s) { return decodeURIComponent(s.replace(pl, " ")); },
params = {};
while (match = search.exec(query))
params[decode(match[1])] = decode(match[2]);
if (params["contextid"]) return decodeURIComponent(hmContextIds[params["contextid"]]);
else return "";
}