Language Localization with Google Maps API

When you include a Google Maps to your website via the Google Maps JavaScript API uses the browser's set preferred language to display the texts. Sometimes this doesn't turned out as planned and you want to be able to override this with your own choice.

Google Maps

Changing language is done with an additional argument when referencing the script-file. The argument used is language.

<script type="text/javascript"
    src="http://maps.google.com/maps/api/js?sensor=false&language=ja">

There is of course a reference to the supported languages and their language codes.

Region Localization

To set the language of the names of the countries, cities and other places, you can use the Region Localization.

Comments