Sterling Quinn of the Server team contributed this post on configuring your web server to display custom tiles in areas where you have not yet completed your map cache.
At the ESRI Developer Summit, several of you asked how we displayed a “Data not available” tile in empty areas of the ArcGIS Online services. This kind of tile can be useful if someone pans to the edge of the map or navigates to an area that you have not completed caching. Configuring your server to return a “Data not available” tile can in some cases yield a better user experience than returning nothing.
To display the tile, you need to create a custom error response on your virtual cache directory for HTTP Error 404: “Not Found”. Instead of an error message, the Web server returns the tile.
Following are steps for this process in IIS. Before you perform these steps, you should put the blank or “Data not available” tile in your cache directory. The tile you use must have the same dimensions and image format as the other tiles in the cache.
- In IIS Manager, right-click the Virtual Directory for the specific cache and select Properties.
- Click the Custom Errors tab, scroll down, and select the 404 error code.
- Click the Edit button. In the URL box, specify the tile that IIS should return whenever a tile is missing. It is important to use a URL and not just a path to a file.
- Click OK. Your dialog should look similar to the one below. Click OK again to return to IIS Manager.
You can download a sample, “Map data not yet available” tile (512 X 512 JPG) that you can use here.
Commenting is not enabled for this article.