gpt4 book ai didi

google-maps - Google Map InfoWindow 在 Google Chrome 中显示滚动条

转载 作者:行者123 更新时间:2023-12-03 04:06:48 25 4
gpt4 key购买 nike

由于某种原因,InfoWindow 与内容一起显示滚动条,我尝试为 InfoWindow 设置自定义宽度和高度,但它没有显示。我尝试了这里的解决方案 Google Map Infowindow not showing properly

请引用以下链接 http://server.ashoresystems.com/~contacth/index.php?option=com_business&view=categoryresult&catid=2

  • 点击 1(有滚动条)
  • 点击 3(即使受到干扰)

感谢您的帮助。

最佳答案

我找到了解决方法here .

我做了这个JSfiddle ,显示错误和解决方法。

如果您不想访问外部链接,以下是解决方法说明:

将包装 div 添加到信息窗口内容:

var infoWindow = new google.maps.InfoWindow({
content: '<div class="scrollFix">'+infoWindowContent+'</div>',
[...]
}).open(map);

并使用 CSS 定义来避免滚动条:

.scrollFix {
line-height: 1.35;
overflow: hidden;
white-space: nowrap;
}

关于google-maps - Google Map InfoWindow 在 Google Chrome 中显示滚动条,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/19954893/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com