Google maps are backbone of our Directory themes, What if you can have the map in your own language on the Directory theme? Nice no? Yes, you can translate the Google Map language in your Directory theme or any other theme using Google Maps.

Let’s see how can we achieve this:

  • Open the relative file of MAP from where the map parameters like zooming factor and all are given. You will be able to find a line of code something like this:
  • <script type=”text/javascript” src=”http://maps.googleapis.com/maps/api/js?sensor=false”></script>
  • If you are not able to find the whole line, just try to look for the “src” URL. Replace it with this one:
  • <script type=”text/javascript” src=”http://maps.googleapis.com/maps/api/js?sensor=false&language=es”></script>
  • As you can see that it has only added “&language=es” in to the URL end. es is the language code. You can have a list of available languages and their codes here.
  • There can be some more text after “sensor=false” in your file. At the end of the src just append the language parameter with “&” sign(&language=es).

Google developers are providing more detailed information here – https://developers.google.com/maps/documentation/javascript/basics#Language

Should you have any suggestions/ questions, do let me know here.