In scenarios where the plugin provides external links to Google Maps, sometimes English maps are displayed even if the WordPress locale andMap Languge setting are non-English. This happens because the Google Maps URL is hard-coded in some places.
Correctly Localized Links
The plugin loads the correct version of Google Maps based on the Map Language setting. Therefore any links generated by Google Maps, such as Places links, are correctly localized.
Incorrectly Localized Links
Some links to Google Maps are generated by the plugin, such as View Directions links in info windows. In these cases the URL is hard-coded and therefore not being localized. For example:
Issue Overview
In scenarios where the plugin provides external links to Google Maps, sometimes English maps are displayed even if the WordPress locale and
Map Languge
setting are non-English. This happens because the Google Maps URL is hard-coded in some places.Correctly Localized Links
The plugin loads the correct version of Google Maps based on the
Map Language
setting. Therefore any links generated by Google Maps, such as Places links, are correctly localized.Incorrectly Localized Links
Some links to Google Maps are generated by the plugin, such as
View Directions
links in info windows. In these cases the URL is hard-coded and therefore not being localized. For example:https://github.com/WordImpress/maps-builder-core/blob/master/assets/js/frontend/google-maps-builder.js#L492
Recommended Solution
Ensure that all Google Maps links include a locale parameter like so...
https://maps.google.com/maps?ll=32.715329,-117.157255&z=15&t=m&hl=de-DE&gl=US&mapclient=apiv3&cid=14113054270661276702
...where
hl=de-DE
determines the language of the map.Related
https://secure.helpscout.net/conversation/397520732/8926/?folderId=672189