After publishing a map service using ArcGIS Server 10.1, use the browser on the ArcGIS Server 10.1 machine to access the Http://localhost:6080/arcgis/rest/services page. Then select a map service to enter, on the new Open Map Service page has a feature is "view in ArcGIS JavaScript", click on a new page to see the map. But the JavaScript that is called by the newly opened page. The API is to use the API on ArcGIS Onlie, if the server is not networked and cannot be viewed, can you deploy an offline JavaScript on the server. API, and then use the deployed offline JavaScript instead. What about the API? Sure, no problem.
There is a resource file in the Tomcat server in ArcGIS Server 10.1 that sets the JavaScript that is being invoked. The address of the API, as long as the modification of this resource file is OK. This file address is C:\Program Files\arcgis\server\framework\runtime\tomcat\webapps\arcgis#rest\web-inf \classes\resources\ Rest-config.properties, open this file as long as you change the value of the Jsapi.arcgis and jsapi.arcgis.css inside to the JavaScript that is deployed locally offline. API can be.
Finally, after the modification is complete, restarting the server will be OK.
Modify ArcGIS Server default JS and CSS connection addresses