[ {x: 123456, y:123456, attribute1: "blah"}, ... ]
var params = {param1: "foo"};//params needed by the serverside file $.get('load-data.php', params, function(data) { var graphic; $.each(data, function(key, val) { graphic = new esri.Graphic(new esri.geometry.Point(val.x, val.y, map.extent.spatialReference), yourSymbol, {"attribute1": val.attribute1}, yourInfoTemplate); map.graphics.add(graphic); } });
Hi, I manage some ArcGIS servers and I publish several map services (http://geonb.snb.ca/arcgis/rest/services/). I have a user that wants to embed my map services into their website. The user has a simple point dataset. The user wants to display their point data on top of my map services. I don't want to add the user's point data to my ArcGIS server. I want the user to keep their data on their own web server.How can the user add their point data to the map if it is NOT on ArcGIS server?What format should they store the data (KML? Shape?)What JavaScript function should be used to read the data and add it to the map?Are there any examples on the web?Thanks,Bernie.
サインインしたメンバーは投稿、更新のフォローなどができます。初めてですか?無料アカウントを登録してください。
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.