Widget:Map: различия между версиями

Материал из Ролевой сервер "tales.pw"
Перейти к:навигация, поиск
Строка 19: Строка 19:
  
 
processData(data);
 
processData(data);
 +
 +
console.log('This runs with jQuery support', $);
  
 
RLQ.push(function () {
 
RLQ.push(function () {

Версия 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);

console.log('This runs with jQuery support', $);

RLQ.push(function () {

   console.log('This runs with jQuery support', $);

});

</script>