Wow, Javascript is not that easy - can someone help me make a simple breakthrough just to understand some basic concepts.
Does anyone know how to populate a filteringSelect Dojo dijit with the names of countries from:
http://server.arcgisonline.com/ArcGIS/rest/services/World_Topo_Map/MapServer/6
I have the following code to make a featureLayer:
countryLayer = new esri.layers.FeatureLayer("http://server.arcgisonline.com/ArcGIS/rest/services/World_Topo_Map/MapServer/6",{
mode:esri.layers.FeatureLayer.MODE_SELECTION,
setMaxAllowableOffset:maxOffset(map,1),
outFields:["NAME"]
});
I think the next step is to somehow loop through all the country names and populate the dijit - but I'm struggling with this.
I have my HTML for the dijit something like this, but I'm not even sure if thats right:
<div dojotype="dijit.layout.ContentPane" title="Test" >
<input id="filteringSelect" jsid="filteringSelect" data-dojo-type="dijit.form.FilteringSelect" data-dojo-props="
placeHolder:'Country',
store:countryStore,
searchAttr:'NAME',
name:'NAME'">
</div>