【问题标题】:Google Earth loads KML 2.2 but not Google Maps谷歌地球加载 KML 2.2 但不加载谷歌地图
【发布时间】:2013-01-11 07:47:03
【问题描述】:

我拥有的Google maps script 似乎可以很好地加载example KML from Chicago 文件,但是当I add my own 时,它会失败。 KML 标准是 2.2 - 为什么 Google 地图无法读取它(Google 地球似乎工作正常)?当我尝试validate the file 时,它说有一些错误 - 鉴于这是我从应用程序获得的输出,有什么办法可以解决它?

【问题讨论】:

    标签: google-maps kml


    【解决方案1】:

    geoxml3, KmlLayerGoogle Maps 为我加载你的 kml。我的服务器不支持带有 .kml 扩展名的 KML,就像带有 .xml 扩展名的 XML 因为it isn't configured for the KML/KMZ MIME types,您的服务器上可能会遇到同样的问题。

    请参阅this issue on the Google Maps API v3 issue tracker 了解线路上的“尖峰”。

    另一种选择是查看KmlLayer.getStatus() 返回的内容 (Kml Status:DOCUMENT_NOT_FOUND)。 cta.kml example 返回 Kml 状态:OK。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2011-02-12
      • 2015-10-06
      • 1970-01-01
      • 1970-01-01
      • 2011-03-31
      • 1970-01-01
      • 2015-09-09
      相关资源
      最近更新 更多