Geocodezip地图空侧边栏

时间:2013-05-23 23:30:41

标签: google-maps kml geoxml3

我在网页中使用以下地图示例。 (obtained from an answer in this other question)两者的源代码几乎相同,但我无法使侧边栏中的位置标题出现在客户端服务器中托管的页面中。 (可以在原始页面中查看)

¿你知道这里是否存在兼容性问题,或者我是否可以添加任何额外的代码以使其有效?

这是示例页面: http://www.geocodezip.com/geoxml3_test/v3_geoxml3_kmltest_linktoB.html?filename=http://www.geocodezip.com/xmlProxy060215.asp?https%3A%2F%2Fmaps.google.com%2Fmaps%2Fms%3Fhl%3Den%26ie%3DUTF8%26oe%3DUTF8%26authuser%3D0%26msa%3D0%26output%3Dkml%26msid%3D216330649072490208011.0004daf6e6bfde8dd857d enter image description here

这是客户端服务器中的页面(我只删除了示例按钮,但即使它们没有显示信息): http://www.vitrocar.com.mx/orchard/media/map.html?filename=http://www.geocodezip.com/xmlProxy060215.asp?https%3A%2F%2Fmaps.google.com%2Fmaps%2Fms%3Fhl%3Den%26ie%3DUTF8%26oe%3DUTF8%26authuser%3D0%26msa%3D0%26output%3Dkml%26msid%3D216330649072490208011.0004daf6e6bfde8dd857d enter image description here

1 个答案:

答案 0 :(得分:3)

在我的服务器上使用代理:

http://www.geocodezip.com/xmlProxy060215.asp

击败目的,不会奏效。您需要在服务器上安装代理。

代理用于克服cross-domain restriction on XmlHttprequest(gemlml3使用XmlHttpRequest访问远程KML,它只能访问与网站相同的域中的XML)。