谷歌地图的地理编码总是使用浏览器语言 [英] Google Maps GeoCoding always uses browser language

查看:157
本文介绍了谷歌地图的地理编码总是使用浏览器语言的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用的是谷歌AJAX API加载器,并希望得到在德国的所有信息 所以我加载地图API像这样

I am using the google ajax api loader and want to get all the information in german so I am loading the maps api like this

      google.load(地图,2,{语:德});

google.load("maps", "2", {language : "de"});

我已经试过申,蒙古包,德,de_DE这个连恩与ja_JPbut没有成功。

I have tried deu, ger, de, de_DE and even en and ja_JPbut no success.

对于那些谁不明白我的问题: http://dl.getdropbox.com/u/5910/Jing /2008-11-24_2018.png 你可以在 HTTP尝试://apps.komola。德/ gmaps.htm 地址为英语对英语的浏览器和德国在德国的浏览器

For those who don't understand my problem: http://dl.getdropbox.com/u/5910/Jing/2008-11-24_2018.png you can try it at http://apps.komola.de/gmaps.htm the address is english on the english browser and german on the german browser

推荐答案

这个API文档显示在地图定位的局限性的 HTTP://$c$c.google.com/apis/maps/documentation/#Localization

This API doc indicates the limitations of the map localization http://code.google.com/apis/maps/documentation/#Localization

语言似乎只影响接口(按钮等),base_domain会影响哪些服务,它使用。所以base_domain强制它使用google.de为地理编码服务。

The language appears to just affect the interface (buttons etc), base_domain affects which services it uses. So base_domain forces it to use google.de for the geocoding service.

<script src="http://www.google.com/jsapi?key=KEYHERE" type="text/javascript"></script>

<script type="text/javascript">
     google.load("maps", "2",{language: "de",base_domain: 'google.de'});
     ...
</script>

装载机文档中提到的base_domain。 HTTP://$c$c.google.com/apis/ajax/文档/#GoogleLoad

The loader doc mentions the base_domain. http://code.google.com/apis/ajax/documentation/#GoogleLoad

这篇关于谷歌地图的地理编码总是使用浏览器语言的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆