Question

I've been trying to display my .mbtiles on the browser inside a "map-div". I extracted the .mbtiles into .png tile files and a .json file using mb-util

This is how my server's public_html looks like: enter image description here

Tiles folder: enter image description here

metadata.json inside tiles folder: enter image description here

And main javascript file java.js: enter image description here

Inside java.js there's the code from the Wax connector so I can use the .json to work with Leaflet.

The map in this state does not work.

So I uploaded the mbtiles file to the MapBox hosting and fetch the .json URL. And when the URL http://testit969.host22.com/tileserver/century.json in java.js is replaced by the Mapbox generated .json URL, it displays the map (although the interactivity doesn't work). This shows me at least that the code is sufficient to display a map provided the .json file is OK.

But right now, the map doesn't display at all. It displays the Leaflet map container only in gray.

Any help would be appreciated.

Was it helpful?

Solution

Please use MapBox.js v1.x or later - the old-style Wax/Leaflet integration is no longer supported. And we can give better assistance in support.mapbox.com.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top