當前位置: 首頁>>編程示例 >>用法及示例精選 >>正文


JavaScript ArcGIS config.portalUrl用法及代碼示例

基本信息

以下是所在類或對象的基本信息。

AMD: require(["esri/config"], (esriConfig) => { /* code goes here */ });

ESM: import esriConfig from "@arcgis/core/config";

對象: esri/config

自從:用於 JavaScript 4.0 的 ArcGIS API

用法說明

config.portalUrl函數(或屬性)的定義如下:

portalUrl String


新門戶實例的默認 URL。如果使用 on-premise 門戶,則應將此值設置為門戶實例,例如:https://www.example.com/arcgis

默認值:"https://www.arcgis.com"

例子:

// Set the hostname to the on-premise portal
esriConfig.portalUrl = "https://myHostName.esri.com/arcgis"

相關用法


注:本文由純淨天空篩選整理自arcgis.com大神的英文原創作品 config.portalUrl。非經特殊聲明,原始代碼版權歸原作者所有,本譯文未經允許或授權,請勿轉載或複製。