android - 将 Esri ArcGIS 4.3 中的 basemap URL 更改为以 https ://instead of file://开头

标签 android cordova arcgis-js-api esri-maps

我正在使用 Esri ArcGIS JS 4.3 构建一个 cordova 应用程序,但 basemap url 有问题。

它们被定义为://services.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer 当我的 Android 应用程序请求资源时,它被翻译成 file://services.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer

如何将 file:// 更改为 https:// 以使请求有效?

最佳答案

好吧,正如我在这里看到的,您希望项目中有 secured(https) url。

在您的情况下,您可以如下所述转换您的 url-

较早的链接-

//services.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer

新 basemap url-

https://services.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer

从技术上讲,这两个 url 是相同的,它将按预期工作。

希望这对你有帮助:)

关于android - 将 Esri ArcGIS 4.3 中的 basemap URL 更改为以 https ://instead of file://开头,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/43348997/

相关文章:

java - 具有动态部分的 RecyclerView

java - 前台服务意外停止

android - 使用 Cordova 在 Android 中记录并获取音量以生成波形

android - 我如何使用 phonegap for android 调用网络服务

ios - 如何在 iOS 中覆盖 Cordova 的 audioCapture 接口(interface)?

javascript - arcgis javascript api map div 上的 Bootstrap 容器设计

gis - 使用 ArcGIS API for JavaScript 在 3D 中堆叠拉伸(stretch)多边形

android - 我应该在自定义适配器或 Activity 中更改 ListView 行的背景吗

java - 无法将广告放置在线性布局的底部

javascript - 如何使用 dojo/store/JsonRest 工作 ArcGIS Rest Service