谷歌地图或开放层认为我在IPHONE?

时间:2010-12-17 14:07:12

标签: google-maps-api-3 openlayers

今天上午开始工作,发现这个新窗口在o​​penlayers上的google maps api v3数据层中弹出。有谁知道它是什么或它来自哪里?之前看过吗?代码指向一堆标记为i-phone的图像和类,所以我怀疑其中一个API认为我在iphone上。

这是弹出的框: alt text

以下是生成框的代码:

<div style="position: absolute; font-family: Arial,sans-serif; z-index: 1100; overflow: visible; -moz-user-select: none; cursor: default; width: 300px; height: 180px;" class="olLayerGoogleCopyright olLayerGoogleV3"><img style="width: 300px; height: 180px; -moz-user-select: none; border: 0px none; padding: 0px; margin: 0px; position: relative; opacity: 0.9;" src="http://maps.gstatic.com/intl/en_us/mapfiles/iphone-dialog-bg.png"><div style="font-weight: bold; color: white; text-align: center; padding: 5px; position: absolute; left: 0px; top: 0px; font-size: 16px; width: 290px;">Map Data</div><div style="position: absolute; font-family: inherit; bottom: 15px; cursor: pointer; background-color: transparent; border: 0pt none; padding: 0pt; margin: 0pt; font-size: 14px; left: 90px; width: 120px; height: 40px;"><img style="position: absolute; left: 0px; top: 0px; width: 120px; height: 40px; -moz-user-select: none; border: 0px none; padding: 0px; margin: 0px;" src="http://maps.gstatic.com/intl/en_us/mapfiles/iphone-dialog-button.png"><span style="color: white; text-align: center; width: 100%; height: 100%; background-color: transparent; position: absolute; left: 0px; top: 0px; padding-top: 10px;">Close</span></div><div style="color: white; text-align: center; font-size: 14px; position: absolute; left: 25px; top: 45px; width: 250px;"></div></div>

1 个答案:

答案 0 :(得分:1)

我遇到了同样的问题。这似乎已经为我修好了。我改变了这个:

<script src="http://maps.google.com/maps/api/js?sensor=false"></script> 

到此:

<script src="http://maps.google.com/maps/api/js?v=3.2&sensor=false"></script>