Widget:Map: различия между версиями
Материал из Ролевой сервер "tales.pw"
Xunto (обсуждение | вклад) |
Xunto (обсуждение | вклад) |
||
| Строка 19: | Строка 19: | ||
processData(data); | processData(data); | ||
| + | |||
| + | RLQ.push(function () { | ||
| + | console.log('This runs with jQuery support', $); | ||
| + | }); | ||
| + | |||
</script> | </script> | ||
Версия 03:58, 29 июля 2019
<script> var data = document.querySelector("#map_data").innerHTML; var state_map = {};
function processData(d) { while (d.length > 0) { var s = d.indexOf("("); var e = d.indexOf(")");
var page = d.substring(0, s - 1); var map = d.substring(s + 1, e);
d = d.substr(e + 3);
state_map[map] = page; } }
processData(data);
RLQ.push(function () {
console.log('This runs with jQuery support', $);
});
</script>