Map not showing up in Safari

1,420 views
Skip to first unread message

Aaron Charlton

unread,
Feb 27, 2017, 8:42:48 PM2/27/17
to Leaflet
My map is not showing up in Safari, but it works in Chrome. I think it's because I've got something out of order. Any ideas what it could be?

Enter code here...var map = L.map('map', {doubleClickZoom: false}).locate({setView: true, maxZoom: 10});

L.control.scale().addTo(map);

L.tileLayer( 'http://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', {
    attribution: '&copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a>',
    subdomains: ['a','b','c']
}).addTo( map );

var markers = L.markerClusterGroup();
var mulchRequests = L.geoJson(mulchRequests, {
onEachFeature: function (feature, layer) {
layer.bindPopup( feature.properties.street + '<br /><a href="https://www.mulchberry.com/mulch/tree-services/get-contact-info/?requester=' + feature.id + '">Get contact info</a>');
}
});
markers.addLayer(mulchRequests);
map.addLayer(markers);
map.fitBounds(markers.getBounds());


Aaron Charlton

unread,
Mar 15, 2017, 10:58:57 AM3/15/17
to Leaflet
SOLVED: The problem is that my site is https, but the map link to openmaps in my header was http, so Safari was blocking the unsecure content. I found the problem in Safari by clicking "view source" and then looking through the debugger tabs. Anyway, adding the 's' fixed the problem. 


On Monday, February 27, 2017 at 5:42:48 PM UTC-8, Aaron Charlton wrote:
My map is not showing up in Safari, but it works in Chrome. I think it's because I've got something out of order. Any ideas what it could be?

cuon...@pycogroup.com

unread,
Jun 3, 2018, 11:34:13 PM6/3/18
to Leaflet
Thank you.
Reply all
Reply to author
Forward
0 new messages