Map just keeps trying to load in Chrome/Firefox but works great in Internet Explorer...any ideas??
Using:
<script type="text/javascript" src="http://js.arcgis.com/3.10/"></script>
Thanks in advance for any suggestions!
Nathan,
Try this fiddle. I think I have all the issues worked out
Edit fiddle - JSFiddle
Hi Nathan,
Most likely there are other javascript code in your page which is not compliant with chrome/firefox.
Use firebug or chrome developer tool (F12) to identify the line where you are getting exception.
Hey Riyas,
Thanks for responding to both posts. So I tried firebug and was unable to find any exceptions. Is there something I can paste in here from that to help determine the problem?
Thanks again!
Can you make a demo in JSBin or JSFiddle that would illustrate this?
And since this is a Javascript question, you should move it to that space and add some appropriate tags. This will help others when searching on this problem.
I am not very familiar with actually creating a JSFiddle example, but I tried. Let me know if I need anything else in there please. Thanks!
http://jsfiddle.net/nlindley/e2cytwky/
maybe check an if it's https issue
do you have any secure content on the page
sometimes mixed content displays fine in IE and Firefox and Chrome block it with little indication of what is actually happening.
Example
When the url is https the map will not load in Firefox or Chrom (insecure content) but loads fine in IE
https://gisweb.cc.lehigh.edu/campusmap/index.html
This url without the https loads fine
http://gisweb.cc.lehigh.edu/campusmap/index.html
There is no secure content on the page so I don't think that is the issue.
Thanks for the reply though Scott.
So after a little more digging I did find an error:
I tried adding the following require but got the same error:
dojo.require("esri/symbols/SimpleMarkerSymbol")
This is my markerSymbol var:
var markerSymbol = new esri.symbol.SimpleMarkerSymbol(esri.symbol.SimpleMarkerSymbol.STYLE_SQUARE, 28, new esri.symbol.SimpleLineSymbol(esri.symbol.SimpleLineSymbol.STYLE_SOLID, new dojo.Color([27, 236, 86]), 0.75), new dojo.Color([255, 0, 0, 0.30]));
Issue has been fixed by moving the variable declarations to after the dojo.AddOnLoad(init). Not sure why this fixed it, but it is fixed. Thanks for all of the suggestions!
Edit: This is not the correct solution. It just lets the maps load before the error occurs again and then the markers do not display.
Not trying to bump/whatever, just want to make sure people know this is not a solved issue.
Thanks for all of the help!
Can you post your code or add it to a fiddle to have it reviewed for errors?
Robert,
I tried to do a jsfiddle which is Edit fiddle - JSFiddle but I am not sure how to load a public map in.
Basically this code is what is causing an error in firefox/chrome but works perfect in IE:
Error:
So you are using
and the correct object name is esri.symbols.SimpleMarkerSymbol
var markerSymbol = new esri.symbols.SimpleMarkerSymbol(esri.symbol.SimpleMarkerSymbol.STYLE_SQUARE, 28, new esri.symbol.SimpleLineSymbol(esri.symbol.SimpleLineSymbol.STYLE_SOLID, new dojo.Color([27, 236, 86]), 0.75), new dojo.Color([255, 0, 0, 0.30]));
Přihlášení členové mohou přispívat, sledovat aktualizace a další. Jste tu noví? Zaregistrujte si bezplatný účet.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.