From: philipp Date: Wed, 18 Sep 2013 19:50:53 +0000 (+0000) Subject: XML entities like & are now decoded correctly by omitting the "; $output .= "\n"; return $output; diff --git a/wrmap.js b/wrmap.js index 76c69da..2bfc787 100644 --- a/wrmap.js +++ b/wrmap.js @@ -2,11 +2,9 @@ function init_wrmap(i, jq_map) { jq_map = $(jq_map); - var jq_map_script = jq_map.children(); OpenLayers.ImgPath = jq_map.attr('data-img-path'); // e.g. "/mediawiki/extensions/wrmap/openlayers/img/" - var json_string = jq_map_script.text(); - jq_map_script.detach(); - + var json_string = jq_map.text(); + jq_map.empty(); // once parsed, remove geojson string from the map element. // extract, tranform and split features to layers var EPSG4326 = new OpenLayers.Projection("EPSG:4326"); // lon/lat diff --git a/wrmap.php b/wrmap.php index 7cf4e01..f759922 100644 --- a/wrmap.php +++ b/wrmap.php @@ -143,8 +143,8 @@ Definition coordinates. -For transmitting the map to javascript, geojson is used in a