laptop and a wrench

Bug

Add support for https to VE (Virtual Earth) tiled layer.

Zuletzt veröffentlicht: August 25, 2014 No Product Found
Bug-ID-Nummer NIM074516
EingereichtOctober 24, 2011
Zuletzt geändertJune 5, 2024
Gilt fürNo Product Found
Gefunden in Version10.1
Behoben in VersionArcGIS.c
StatusFixed

Workaround

Use esri.setRequestPreCallback() to modify requests for Bing tiles to use https or modify the VETiledLayer prototype.Using setRequestPreCallback: esri.setRequestPreCallback(function(ioArgs) { if(ioArgs.url.search("<a href="http://serverapi.arcgisonline.com/veadaptor/" target="_blank">serverapi.arcgisonline.com/veadaptor/</a>") > 0) { ioArgs.url = ioArgs.url.replace("http:", "https:"); } return ioArgs; }); //Creates the Virtual Earth layer to add to the map veTileLayer = new esri.virtualearth.VETiledLayer({ bingMapsKey: 'Ah29HpXlpKwqVbjHzm6mlwMwgw69CYjaMIiW_YOdfTEMFvMr5SNiltLpYAcIocsi', mapStyle: esri.virtualearth.VETiledLayer.MAP_STYLE_AERIAL }); dojo.connect(veTileLayer, "onLoad", function(veTileLayer) { veTileLayer.tileServers = dojo.map(veTileLayer.tileServers, function(tileServer) { return tileServer.replace("http:", "https:"); }); });Modifying the prototype: var ve_gti = esri.virtualearth.VETiledLayer.prototype._getTileInfo; esri.virtualearth.VETiledLayer.prototype._getTileInfo = function () { this.url = "<a href="https://serverapi.arcgisonline.com/veadaptor/production/services/imagery/getmetadata" target="_blank">https://serverapi.arcgisonline.com/veadaptor/production/services/imagery/getmetadata</a>"; this._url = esri.urlToObject(this.url); return ve_gti.apply(this, arguments); }; var ve_il = esri.virtualearth.VETiledLayer.prototype._initLayer; esri.virtualearth.VETiledLayer.prototype._initLayer = function (response) { if (response) { response.imageUri = response.imageUri.replace("http:", "https:"); } return ve_il.apply(this, arguments); }; var veTileLayer = new esri.virtualearth.VETiledLayer({ bingMapsKey: '<key>', mapStyle: esri.virtualearth.VETiledLayer.MAP_STYLE_AERIAL });

Schritte zur Reproduzierung

Bug-ID: NIM074516

Software:

  • No Product Found

Benachrichtigung erhalten, wenn sich der Status eines Bugs ändert

Esri Support App herunterladen

Weitere Informationen zu diesem Thema erkunden

Unterstützung durch ArcGIS-Experten anfordern

An den technischen Support wenden

Esri Support App herunterladen

Zu Download-Optionen wechseln