Select to view content in your preferred language

JSAPI Local Works, Esri Server Doesn't

492
1
02-28-2011 01:47 PM
MatthewLawton
Deactivated User
I have seen this issue danced around a bit on some forum posts, but I haven't been able to gather a definitive solution.

There is an issue that appears to pertain only to Internet Explorer having to do with the JSAPI reference in the SCRIPT tag. If I reference the JSAPI that I have installed on my local server, as below, then IE consumes it with no problem.

<script type="text/javascript" src="/arcgis_js_api/library/1.5/arcgis/">


However, if I attempt to reference the Esri API server, as below, then IE doesn't like it and throws up errors like "Invalid Character" and so forth.

<script type="text/javascript" src="http://serverapi.arcgisonline.com/jsapi/arcgis/?v=1.5">


Firefox is immune to this. I have heard that this is because IE tries to read the markup before it runs the JavaScript or that there is just an inherent loss of speed when trying to access the Esri server, therefore the JSAPI can't load quickly enough in IE before the application tries to execute.

I am really trying to make my applications more portable and would like to reference the Esri server API insead of my local install. What is the solution to this problem?
0 Kudos
1 Reply
MatthewLawton
Deactivated User
Nevermind. I found that when I published to my external web server outside of my firewall that the Esri API reference works fine. Apparently there is some sort of blocking or delay that doesn't allow me to use that reference on my internal developments server.
0 Kudos