Hello Everyone, in my appliation i am using esri basemap gallery and all the labels are in german language. I think this is happening because of our location is in Germany. But I need to show the basemap gallery map labels into English.
How I can do it?
My map.js basemap coding is as follows:
var basemapGallery = new BasemapGallery({
showArcGISBasemaps: true,
map: map
}, "basemapGallery");
basemapGallery.on('load',function(){
basemapGallery.remove('basemap_1');
basemapGallery.remove('basemap_2');
//basemapGallery.remove('basemap_3');
basemapGallery.remove('basemap_4');
basemapGallery.remove('basemap_5');
//basemapGallery.remove('basemap_6');
basemapGallery.remove('basemap_7');
//basemapGallery.remove('basemap_8');
//basemapGallery.remove('basemap_9');
//basemapGallery.remove('basemap_10');
});
//esriConfig.defaults.map.zoomDuration = 0;
//esriConfig.defaults.map.zoomRate = 0;
//Add Dynamic Layers
featureLayer = new ArcGISDynamicMapServiceLayer("https://......../MapServer", {
opacity: 1
});
//map.addLayer(featureLayer);
map.addLayers([baseMap,featureLayer]);
Regards
M.Zoarder
Solved! Go to Solution.
Muqit,
to force a locale you use this block of code in your app:
<script type="text/javascript">
dojoConfig = {
locale: "en",
parseOnLoad: false
};
</script>
Muqit,
Would it be OK if the whole app used English?
Robert, we have two version of our app. One is in german and another is in english. We need english lables for basemap gallery for English version. Please visit our app : Dauerfeldversuche Deutschland
Can you please suggest me how can I convert the lables in basemap gallery?
Thanks
Muqit,
to force a locale you use this block of code in your app:
<script type="text/javascript">
dojoConfig = {
locale: "en",
parseOnLoad: false
};
</script>
In my index.php i have changed the code :
but not working !!
My mistake in code, thanks now it is working.