添加透明度图片后,Google地图是静态的

时间:2014-03-28 19:56:12

标签: google-maps-api-3

我在谷歌地图中添加了透明图像,看起来很好,但现在我无法点击地图移动或放大,我无法点击标记。然而,奇怪的是,我实际上可以移动地图并点击标记,但前提是我点击地图的非常外边缘。我已经摆弄了所有代码,似乎无法使其正常运行。当地图图层移动到前面时,我才能真正使用地图,但随后透明度消失......任何反馈都会受到赞赏......

<!DOCTYPE html>
<html> 
<head> 
<meta http-equiv="content-type" content="text/html; charset=UTF-8" /> 
<title>Google Map</title> 
<script src="http://maps.googleapis.com/maps/api/js?sensor=false"></script>
</head> 
<body>
<center>
<p>
<div id="map" style="height: 100%;
position: absolute;
top: 0;
bottom: -200px;
left: 0;
right: 0;
border-bottom-width:77px;
border-bottom-color:black;
border-bottom-style: solid;
z-index: -1;"></div>

<script src="scripts/mapmarkers.js"></script>

<p>
<div align="left"><img src="images/transimage.png" width="500" height="550" /></div>

1 个答案:

答案 0 :(得分:0)

这是一个有效的解决方案:

<div style="position: absolute; left: 3%; top: 0%;">
<img src="image.png" width="50" height="50"></div>