[Fix included] Localizing the Google Map using Craft site locale
Not sure how MR works, I drop the fix here, hoping magic happens.
File: /src/services/EmbedService.php somewhere near line 144
$params = http_build_query([
'key' => $settings->getMapToken(),
// add next line to make the map load using the site language
'language' => Craft::$app->getLocale()->getLanguageID(),
'callback' => $callbackName,
]);
I guess the same trick also applies to other map providers?
Thanks for suggesting this, @rtrudel. We'll take a look and adjust on our end as necessary.
Perhaps it could be more clean to get the currentSite locale, I'm not sure. But I'm sure you'll do for the best :)
Can't understand why, for me, doesn't get the currentSite locale. I have the cp setted in english. Only english available site and it shows to me the country field in italian language. So weird. Is there a possibility to force it through a config file?