HowTo: Install the JavaScript API for use with ArcGIS 10.2 for Server
【相关信息】
Article ID: 42138
Software:
ArcGIS API for JavaScript 3.8
ArcGIS for Server 10.2
Platforms:
Windows Server 2008, Windows 7, Server 2008 R2
【问题描述】
When using ArcGIS for Server in an isolated or secure environment, it may not be possible to access the hosted Esri JavaScript API libraries. This article provides a walkthrough for installing a local copy of the JavaScript API and configuring it for use with ArcGIS 10.2 for Server.
Article ID: 42138
Software:
ArcGIS API for JavaScript 3.8
ArcGIS for Server 10.2
Platforms:
Windows Server 2008, Windows 7, Server 2008 R2
【问题描述】
When using ArcGIS for Server in an isolated or secure environment, it may not be possible to access the hosted Esri JavaScript API libraries. This article provides a walkthrough for installing a local copy of the JavaScript API and configuring it for use with ArcGIS 10.2 for Server.
1 个回复
EsriSupport
赞同来自:
Download and install the JavaScript API
1. Navigate to the
ArcGIS API for JavaScript page.
2. Under the Download section, click the link to the ArcGIS API for JavaScript section of the
Esri Download page.
3. Scroll down to the latest ArcGIS API for JavaScript API release (currently v3.8).
4. Click the 'arcgis_js_v38_api.zip' link and log in with an Esri Global Account username and password.
5. Accept the License Agreement to start the download.
Modify JavaScript files 1. Unzip the contents of the .zip file to a temporarily location.
2. Copy the arcgis_js_api folder into the web server root folder, typically:
C:\inetpub\wwwroot
3. Open the following file in a text editor:
C:\Inetpub\wwwroot\arcgis_js_api\library\3.8\3.8\init.js
4. Search for the text '[HOSTNAME_AND_PATH_TO_JSAPI]', and replace this text with:
<myhost.example.com>/arcgis_js_api/library/3.8/3.8/
5. Open the following file in a text editor:
C:\Inetpub\wwwroot\arcgis_js_api\library\3.8\3.8\js\dojo\dojo\dojo.js
6. Search for the text '[HOSTNAME_AND_PATH_TO_JSAPI]', and replace this text with:
<myhost.example.com>/arcgis_js_api/library/3.8/3.8/
Add IIS default document 1. Open IIS and navigate to the Default Web Site. 2. Open the Default Document.
3. Under the Actions heading, click Add.
4. Type init.js as the name value, and click OK.
Init.js should now be listed as a Local Entry Type default document.
Edit ArcGIS services 1. In a web browser on the server navigate to the following location:
http://localhost:6080/arcgis/a ... ctory
2. Login with administrator credentials.
3. Copy or take a screenshot of the current Services Directory settings in case it is necessary to revert to the default settings.
4. Click 'edit' to modify settings.
5. Replace each of the following fields with the path to the local installation of the JavaScript API using the fully qualified host name in place of the following examples:
Javascript API URL:
http://myhost.example.com/arcg ... /3.8/
Javascript API CSS URL:
http://myhost.example.com/arcg ... a.css
Javascript API CSS2 URL:
http://myhost.example.com/arcg ... i.css
6. Clear the browser cache to complete installation.
【其它相关参考】
【创建及修改时间】
Created: 1/3/2014
Last Modified: 6/26/2014
【原文链接】
http://support.esri.com/en/kno ... 42138
要回复问题请先登录或注册