{"id":13326646,"date":"2020-08-28T07:30:57","date_gmt":"2020-08-28T07:30:57","guid":{"rendered":"https:\/\/wordpress.org\/support\/topic\/leaflet-js-map-no-longer-displays\/"},"modified":"2020-08-28T07:30:57","modified_gmt":"2020-08-28T07:30:57","slug":"leaflet-js-map-no-longer-displays","status":"publish","type":"topic","link":"https:\/\/wordpress.org\/support\/topic\/leaflet-js-map-no-longer-displays\/","title":{"rendered":"Leaflet JS map no longer displays"},"content":{"rendered":"<p>Hello,<\/p>\n<p>I am using the ACF Openstreetmap Field 1.2.1 plugin<br \/>\nand the following plugins:<br \/>\nElementor 3.0.3 + elementor pro 3.0.1 + Advanced Custom Fields 5.9+Insert PHP Code Snippet 1.31.1<\/p>\n<p>I created a php snippet named [xyz-ips snippet = &#8220;carte-osm&#8221;]<br \/>\n&lt;? php $ note = get_field (&#8216;carteosm&#8217;); ?&gt;<br \/>\n&lt;? php the_field (&#8216;carteosm&#8217;); ?&gt;<\/p>\n<p>which I display via &#8220;text editor widget elementor&#8221; with the php Snippet named [xyz-ips snippet = &#8220;map-osm&#8221;]<\/p>\n<p>It was working perfectly and now I have the following error<\/p>\n<p>The Leaflet card is all gray, there are only the + and &#8211; buttons at the top left and the leaflet link at the bottom right<\/p>\n<p>with the following error in the Google Chrome console<\/p>\n<p>JQMIGRATE: Migrate is installed, version 1.4.1<br \/>\nacf-osm-frontend.min.js? ver = 1.2.1: 1 Uncaught TypeError: Unable to read property &#8216;OpenStreetMap&#8217; from null<br \/>\n    to e.initialize (acf-osm-frontend.min.js? ver = 1.2.1: 1)<br \/>\n    to the new e (acf-osm-frontend.min.js? ver = 1.2.1: 1)<br \/>\n    at Function.u.tileLayer.provider (acf-osm-frontend.min.js? ver = 1.2.1: 1)<br \/>\n    to String. &lt;anonymous&gt; (acf-osm-frontend.min.js? ver = 1.2.1: 1)<br \/>\n    at Function.each (jquery.js? ver = 1.12.4-wp: 2)<br \/>\n    at HTMLDivElement. &lt;anonymous&gt; (acf-osm-frontend.min.js? ver = 1.2.1: 1)<br \/>\n    at HTMLDivElement. &lt;anonymous&gt; (acf-osm-frontend.min.js? ver = 1.2.1: 1)<br \/>\n    at Function.each (jquery.js? ver = 1.12.4-wp: 2)<br \/>\n    at a.fn.init.each (jquery.js? ver = 1.12.4-wp: 2)<br \/>\n    on a.fn.init.acf_leaflet (acf-osm-frontend.min.js? ver = 1.2.1: 1)<\/p>\n<p>can you tell me how to fix this bug? <\/p>\n<p>Thanks you in advance<\/p>\n","protected":false},"template":"","class_list":["post-13326646","topic","type-topic","status-publish","hentry"],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/13326646","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic"}],"about":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/types\/topic"}],"version-history":[{"count":0,"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/topic\/13326646\/revisions"}],"wp:attachment":[{"href":"https:\/\/wordpress.org\/support\/wp-json\/wp\/v2\/media?parent=13326646"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}