On-Premise basemap

1283
1
12-02-2014 09:39 AM
StephenCoppola
New Contributor III

Good Afternoon colleagues,

In JavaScript how does one setup basemap URLs that are not from arcgis-online.  We have an on-premise system which basemaps are coming from another ArcGIS server.  For example, we are referencing common basemaps, such as:

  • ArcGISTiledMapServiceLayer

"https://services.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer"

  • ArcGISTiledMapServiceLayer

"https://services.arcgisonline.com/ArcGIS/rest/services/World_Street_Map/MapServer"

  • ArcGISTiledMapServiceLayer

"https://services.arcgisonline.com/ArcGIS/rest/services/World_Topo_Map/MapServer"

I am new to JavaScript and coding with ESRI JavaScript packages.  A few questions:

  1. Are these the correct MapServiceLayer objects used for each?
  2. If I wanted to change the URL to a local service, what are the steps to take?
    1. Are there additional steps if the web app uses an proxy?

Your time and suggestions are greatly appreciated.  Thank you for your insight. 

0 Kudos
1 Reply
JohnGravois
Frequent Contributor

1. yes, those are the urls which refer to our most popular hosted basemaps.

2. if you just need to load a single ArcGISTiledMapServiceLayer in your application, check out this sample.

if you are using the BasemapGallery widget and would like to substitute custom layers, check out this one.

0 Kudos