【问题标题】:Google Maps iframe browser not displaying谷歌地图 iframe 浏览器不显示
【发布时间】:2013-12-04 06:04:38
【问题描述】:

几年前这种类型的东西工作得很好。这在 Chrome / FF 中不起作用,但在 IE 中,至少我会收到有关未显示内容的警告,我可以在显示地图的新 IE 窗口中生成它。我对为什么没有显示带有谷歌地图的标准引导 css 和 iframe 感到困惑。

        <div class="row">
            <div class="col-md-12">
                <!-- Google maps -->
                <div class="gmap">
                    <!-- Google Maps. Replace the below iframe with your Google Maps embed code -->
                    <iframe height="300" frameborder="0" scrolling="no" marginheight="0" marginwidth="0" src="https://maps.google.com/maps?q=Acton,+MA&hl=en&sll=42.036922,-71.683501&sspn=2.647686,3.532104&oq=Acton&hnear=Acton,+Middlesex,+Massachusetts&t=m&z=12"></iframe>
                </div>

            </div>
        </div>

【问题讨论】:

    标签: google-maps twitter-bootstrap iframe


    【解决方案1】:

    这不是谷歌地图提供的正确嵌入代码。

    网址中缺少参数output=embed

    如果没有这个参数,框架将被重定向到新的谷歌地图,其中没有
    将发送适当的 X-Frame-Options -header(阻止浏览器显示 iframe)

    【讨论】:

    • 是的,将此添加到 url 的末尾 &output=embed 谢谢!
    猜你喜欢
    • 1970-01-01
    • 2017-08-29
    • 1970-01-01
    • 1970-01-01
    • 2022-10-08
    • 2017-12-28
    • 1970-01-01
    • 1970-01-01
    • 2011-07-27
    相关资源
    最近更新 更多