0

I have this MapServer

http://geoservices.big.go.id/arcgis/rest/services/RBI/Rupabumi/MapServer

It turns out it uses 4326 spatial reference.

I want to present it using leaflet, my code so far:

    var map = new L.Map('map', {
    crs: L.CRS.EPSG4326
  }).setView([-6.1333, 106.75], 0);

  L.esri.tiledMapLayer('http://geoservices.big.go.id/arcgis/rest/services/RBI/Rupabumi/MapServer', {
    maxZoom: 14,
    minZoom: 0,
    continuousWorld: false,
    noWrap : false
  }).addTo(map);

But the map is not showing up. I found that http://geoservices.big.go.id/arcgis/rest/services/RBI/Rupabumi/MapServer/tile/0/20/25 will give me a tile, but the request from leaflet stops at /0/0/0. Can anybody help me?

1

As stated in the Esri Leaflet API Reference:

Your map service must be published using the Web Mercator Auxiliary Sphere tiling scheme (WKID 102100/3857) and the default scale option used by Google Maps, Bing Maps and ArcGIS Online. Esri Leaflet will not support any other spatial reference for tile layers.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.