Select to view content in your preferred language

Adding Reference Layer over World Imagery Basemap with Folium

1672
0
12-29-2022 07:38 AM
AaronHester
New Contributor II

I'm trying to add a reference layer like this vector tile layer from ArcGIS Online on top of another basemap using folium (with names of towns and cities, street names, etc.) . The reference layer displays in the layer control window, but isn't visible on the map.

Here's the code I used to add it to the map:

m = folium.Map(coord, zoom_start=13, tiles=None)

tile = folium.TileLayer(
tiles='https://server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer/tile/{z}/{y}/{x}',
attr='Esri',
name='Esri Satellite',
overlay=False,
control=True
).add_to(m)

tileRef = folium.TileLayer(
tiles='https://basemaps.arcgis.com/arcgis/rest/services/World_Basemap_v2/VectorTileServer/tile/{z}/{y}/{x}',
attr='Esri',
name='Esri Vector Tile Layer',
overlay=True,
control=True
).add_to(m)

AaronHester_0-1672327860114.png

Does anyone have any ideas on where I've gone wrong?

0 Kudos
0 Replies