I'm using Esri js api 3.7 and "esri/layers/WMSLayer" to add WMS layers to my map.
The WMS GetCapabilities response has content-type application/vnd.ogc.wms_xml (from MapServer).
In Chrome (v. 31.x) the xhr object returns null, and not the xml document. It works fine in FireFox. So the capability xml file is not loaded, and the wms does not show up in the map.
It seems like Chrome does not handle the response as text/xml, and instead returns null.
If I change the response content-type from application/vnd.ogc.wms_xml to text/xml (using Fiddler), it also works in Chrome.
Has anyone else have experiences this?
I have found 2 workarounds:
1) Create an resourceInfo object(optional parameter in creating wms layer). This prevents the GetCapabilities request.
There are many services and layers, so this is not an prefered option..
2) Use my own old custom WMS-layer object(inherit esri/layers/TiledMapServiceLayer). It does not ask for GetCapabilities.
Any other tips/workarounds?
Should the Esri js api handle this?
-Endre