Problem in displaying WorldHydroReferenceOverlay

1608
8
12-03-2012 07:58 AM
PabitraDash
New Contributor
I am trying to add the WorldHydroReferenceOverlay layer to my basemap and seems it is not getting added as I don't see this layer on my map when viewing the map. Here is my sample code:

var myMap = new esri.Map("mapDiv");

        var baseMap = new esri.layers.ArcGISTiledMapServiceLayer("https://server.arcgisonline.com/ArcGIS/rest/services/World_Topo_Map/MapServer");
        myMap.addLayer(baseMap);

var referenceLayer = new esri.layers.ArcGISTiledMapServiceLayer("https://184.72.212.114:6080/arcgis/rest/services/WorldHydroReferenceOverlay/MapServer"); 
       
        myMap.addLayer(referenceLayer);

dojo.addOnLoad(init);

I see the world topo map when viewing the webpage, but not the
hydro map layer.

Any help would be appreciated.
PK
0 Kudos
8 Replies
JeffPace
MVP Alum
I am trying to add the WorldHydroReferenceOverlay layer to my basemap and seems it is not getting added as I don't see this layer on my map when viewing the map. Here is my sample code:

var myMap = new esri.Map("mapDiv");

        var baseMap = new esri.layers.ArcGISTiledMapServiceLayer("http://server.arcgisonline.com/ArcGIS/rest/services/World_Topo_Map/MapServer");
        myMap.addLayer(baseMap);

var referenceLayer = new esri.layers.ArcGISTiledMapServiceLayer("http://184.72.212.114:6080/arcgis/rest/services/WorldHydroReferenceOverlay/MapServer"); 
       
        myMap.addLayer(referenceLayer);

dojo.addOnLoad(init);

I see the world topo map when viewing the webpage, but not the
hydro map layer.

Any help would be appreciated.
PK


I dont see the URL as valid, are you sure its correct?
0 Kudos
derekswingley1
Frequent Contributor
I'm able to add it here:  http://jsfiddle.net/ZEBAJ/

What are you doing differently?
0 Kudos
JeffPace
MVP Alum
Browsing the rest service gets a connection refused for me.
0 Kudos
PabitraDash
New Contributor
Browsing the rest service gets a connection refused for me.


I can browse here with no problem:
http://184.72.212.114:6080/arcgis/rest/services/WorldHydroReferenceOverlay/MapServer

PK
0 Kudos
PabitraDash
New Contributor
I'm able to add it here:  http://jsfiddle.net/ZEBAJ/

What are you doing differently?


Since my website is running on https, I am referencing the source for the hydro reference overlay with https and not http and that seems to fail to load this resource. Not sure how to solve this problem.

Thanks
0 Kudos
JohnGravois
Frequent Contributor
you are correct that the protocol used to host your application and retrieve your resources should be the same.  i am able to load the tiled service directly in the browser over HTTP but not HTTPS.  instead i see the error below.  if this is the case for you too perhaps you you might see whether the web server requires a client certificate and remove that restriction prior to retesting to see whether the layer is accessible in an HTTPS JavaScript application.

SSL connection error
Unable to make a secure connection to the server. This may be a problem with the server, or it may be requiring a client authentication certificate that you don't have.
Error 107 (net::ERR_SSL_PROTOCOL_ERROR): SSL protocol error.
0 Kudos
AamirSuleman
New Contributor II
One of our clients is seeing the same issue when accessing https://services.arcgisonline.com using Chrome (latest). Could this be an internal IT issue?

Error message is

Unable to make a secure connection to the server. This may be a problem with the server, or it may be requiring a client authentication certificate that you don't have.
Error code: ERR_SSL_PROTOCOL_ERROR
0 Kudos
AamirSuleman
New Contributor II
Was able to solve by going to Internet Options (easy access from IE, Tools), Advanced Tab, Scroll all the way to the bottom. Check everything that starts with Use SSL or Use TLS
0 Kudos