How to hide "Esri World Geocoder" in the search widght with Arcgis-js-api 3.x
Solved! Go to Solution.
Hi z xz,
Pass in empty source array to clear the default ArcGIS Online World Geocoding service:
sources: []
See this example, showing the defaults ArcGIS Online World Geocoding service:Search multiple sources | ArcGIS API for JavaScript 3.29
No you can modify the code (e.g. in CodePen) to modify the search to remove this default service:
var search = new Search({
enableButtonMode: true, //this enables the search widget to display as a single button
enableLabel: false,
enableInfoWindow: true,
showInfoWindowOnSelect: false,
map: map,
//passing in empty source array to clear the default ArcGIS Online World Geocoding service
sources: []
}, "search");
Does this work for you?
Cheers,
Egge-Jan
Hi z xz,
Pass in empty source array to clear the default ArcGIS Online World Geocoding service:
sources: []
See this example, showing the defaults ArcGIS Online World Geocoding service:Search multiple sources | ArcGIS API for JavaScript 3.29
No you can modify the code (e.g. in CodePen) to modify the search to remove this default service:
var search = new Search({
enableButtonMode: true, //this enables the search widget to display as a single button
enableLabel: false,
enableInfoWindow: true,
showInfoWindowOnSelect: false,
map: map,
//passing in empty source array to clear the default ArcGIS Online World Geocoding service
sources: []
}, "search");
Does this work for you?
Cheers,
Egge-Jan
It works,thank you!
Hi z xz,
If your issue has been solved, you may mark my answer as correct. In this way it will be clear to others - who may have the same question - that your question has been answered correctly.
Cheers,
Egge-Jan