diff options
Diffstat (limited to 'plugins/Mapstraction/map.php')
-rw-r--r-- | plugins/Mapstraction/map.php | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/plugins/Mapstraction/map.php b/plugins/Mapstraction/map.php index 89723f43c..734e48088 100644 --- a/plugins/Mapstraction/map.php +++ b/plugins/Mapstraction/map.php @@ -128,12 +128,9 @@ class MapAction extends OwnerDesignAction } } - $this->elementStart('script', array('type' => 'text/javascript')); - $this->raw('/*<![CDATA[*/'); // XHTML compat for Safari - $this->raw('var _notices = ' . json_encode($jsonArray).'; '); - $this->raw('showMapstraction($("#map_canvas"),_notices);'); - $this->raw('/*]]>*/'); // XHTML compat for Safari - $this->elementEnd('script'); + $this->inlineScript('$(document).ready(function() { '. + ' var _notices = ' . json_encode($jsonArray).'; ' . + 'showMapstraction($("#map_canvas"), _notices); });'); return true; } |