根据下面的截图,我在谷歌地图周围有一个灰色的边框/填充,有人知道如何删除它吗?
谢谢
这是我的代码:
var map;
function initialize(canvas,lat,lng) {
var myOptions = {
zoom: 16,
center: new google.maps.LatLng(lat,lng),
disableDefaultUI: true,
mapTypeId: google.maps.MapTypeId.ROADMAP,
panControl: false,
zoomControl: true,
zoomControlOptions: {
style: google.maps.ZoomControlStyle.SMALL,
position: google.maps.ControlPosition.LEFT_TOP
},
scaleControl: false,
streetViewControl: false,
scrollwheel: false
};
map = new google.maps.Map(document.getElementById(canvas),myOptions);
}
我有 3 页嵌入谷歌地图,我添加了下面的代码来调用谷歌地图
$(document).ready(function() {
initialize("causewayBayMapCanvas","22.281001", "114.186375");
});
更新:
<div style="width:300px; height:200px; border: 1px solid #0051B9">
<div id="<?php echo $mapId;?>" class="map rounded"></div>
</div>