go_maps_ext icon indicating copy to clipboard operation
go_maps_ext copied to clipboard

GroundOverlay has stopped working in TYPO3 12

Open Dani-mam opened this issue 1 year ago • 1 comments

Up until TYPO3 11.5.38 with go_maps_ext 5.1.0 we've had a small script that put an overlay image over the map. Now with TYPO3 12.4.20 and go_maps_ext 6.1.1. it has stopped working and we can't quite figure out why. Any help would be greatly appreciated.

The script:

$(document).ready(function(){ 
  $(function () {
  var mapOverlay;
  var element = $(".js-map");
  
  var imageBounds = {
    north: 52.75099,
    south: 52.74379,
    east: 8.30016,
    west: 8.28697
  };   
  
  //Karte mit Overlay
  mapOverlay = new google.maps.GroundOverlay(
      'https://www.my-website.de/fileadmin/user_upload/img/GoogleMaps/map-overlay.png',
      imageBounds
  );
  mapOverlay.setMap(element.data("map"));
  });	
}); 

Dani-mam avatar Sep 26 '24 12:09 Dani-mam

We removed jQuery.

To get the map try sth like this:

document.querySelectorAll('.js-map').forEach(function(el) { 
       console.log( el.gomapsext.map );
});

mhirdes avatar Oct 11 '24 13:10 mhirdes