Hello, here we have an otherwise lovely Italian WMS containing parcel and land information:
wms.cartografia.agenziaentrate.gov.it/inspire/wms/ows01.php?
However this WMS cannot be displayed in a webmaps that are utilizing the ESRI basemaps on our Portal (but renders fine in ArcGIS PRO and FME Form), the error we are given being: "Incompatible with current basemap", I have looked up that error and since its not our service then there is little we can do. Setting parameter SRS to 25832 does not work either.
When looking at the service using a GetCapabilities and 1.1.0 call I notice that it hasn't got EPSG: 4326 capabilities and I'm wondering if that is causing the issue? Or perhaps if the tiling scheme is off?
It has only these EPSG's enabled:
[EPSG:6706 EPSG:4258 EPSG:3044 EPSG:3045 EPSG:3046 EPSG:25832 EPSG:25833 EPSG:25834]
Anyway, any suggestions how we can get this to work in our applications that rely on ESRI basemaps on our Portal?
PS. Dont call it using 1.3,0 cause then it has the X and Y mixed and the whole thing shows up at the horn of Africa...
Solved! Go to Solution.
You might look at this tutorial:
https://learn.arcgis.com/en/projects/make-a-web-map-without-web-mercator/
and try publishing a basemap in that SRS, then add that basemap to set the CRS for the map viewer, and try adding the service.
Looks like the WMS hosting server is returning a CORS error
Access to fetch at 'https://wms.cartografia.agenziaentrate.gov.it/inspire/wms/ows01.php?SERVICE=WMS&REQUEST=GetCapabilit...' from origin 'https://jsapi.maps.arcgis.com' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled.
More about CORS and the 4.x JS Maps SDK which apps like map viewer, dashboards and experience builder all use and would hit the same issue when trying to draw the layer.
https://developers.arcgis.com/javascript/latest/cors/
You might look at this tutorial:
https://learn.arcgis.com/en/projects/make-a-web-map-without-web-mercator/
and try publishing a basemap in that SRS, then add that basemap to set the CRS for the map viewer, and try adding the service.
Thank you @BobBooth1, that did the trick ✔️