【发布时间】:2016-05-06 11:44:00
【问题描述】:
我正在尝试将我的谷歌地图的宽度和高度设置为 100%。我知道您也需要设置父母,我正在这样做。这就是我所拥有的:
<asp:Content ID="head" ContentPlaceHolderID="head" runat="server">
<style>
#homeBody {
height: 100%;
width: 100%;
}
#map {
width: 100%;
height: 100%;
margin-top: 200px;
}
</style>
</asp:Content>
<asp:Content ID="homeBody" ContentPlaceHolderID="homeBody" runat="server">
<div id="map"></div>
//some scriping to build map and what not
</asp:Content>
谁能告诉我我做错了什么?我目前在页面上只有一条非常细的线......基本上没有高度,只有宽度。
【问题讨论】:
-
请提供一个 Minimal, Complete, Tested and Readable example 来证明问题(最好是浏览器看到的 HTML/CSS)..
标签: css google-maps height