I've called tilecache from OpenLayers in the same manner as the example below. Is it possible to do something similar with the ArcGIS WMS map layer?

var urlArray = ["http://tilecache.osgeo.org/wms-c/Basic.py",
layer = new OpenLayers.Layer.WMS( "OpenLayers WMS", 
    {layers: 'basic'} );
  • What are you trying to achieve there? Multiple tile servers serving the same layer, or several layers with different data stacked in the same layer? Both can be done in the arcgis jsapi (though you would need a wms wrapper). – blord-castillo Jun 17 '11 at 22:17
  • No need for WMS to pull cache from more than one server/domain. I am doing that and it works very nicely. – D.E.Wright Jun 17 '11 at 22:20
  • Multiple tile layers serving the same layer. I'm hoping to achieve more concurrent requests by duplicating the services across several servers. I'm not sure what you're trying to say D.E. but I'm going to experiment a little this morning – Ryan Twilley Jun 20 '11 at 13:35
  • Curious if you ever got tilecache layers to show in esri. The OL code above does not set singleTile: true, which is why it will work (tile size is 256 x 256). The ESRI WMS service does not seem to have a singleTile option, so wondering if you evergot your TileCache tiles to display in ESRI JSAPI (and how). – ca0v Jul 26 '12 at 19:28
  • That's not quite what I was getting at with the original question, but here's how I use TileCache layers within the arcgis api. I use the custom layer example from the arcgis api reference, similar to the 'my.PortlandTiledMapServiceLayer' instance created in this example. Here's the key piece from my 'getTileUrl' code. --> return url + level + "/" + col + "/" + row + "." + img_fmt + "?type=google" – Ryan Twilley Jul 27 '12 at 19:18

You probably want to do it this way...

var streetTemplateLayer = new esri.dijit.esri.layers.ArcGISTiledMapServiceLayer({
                    url: "http://domain.com/ArcGIS/rest/services/Base/Base_Map/MapServer",
                    tileServers: [

This will allow you to define your service, then a list of URLS that host your caches...

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.