自定义地图在卫星视图上被破坏,不显示卫星图像。有什么想法吗,怎么了?套印格式也会损坏-它们不是透明的。
<>代码:
<script src=“http://maps.google.com/maps?”file=api&v=3&sensor=true&key=my key is here“type=”text/javascript“></script>
<script type=“text/javascript”>
函数initialize()。{
if(gbrowseriscompatible()){
var map=new gmap2(document.getElementByID(“map_canvas”));
地图.设置中心(New Glatlng(52.229676,21.012229),13);
map.setmaptype(g_混合图);
map.setuitodefault();
}
var geocoder=new gclientgeocoder();
函数ShowAddress(地址){
geocoder.getlatlng(地址、功能(点){
如果(!)点){
alert('nie mo_¼na znale:adresu:'+地址);
}否则{
地图.设置中心(点,13);
var标记=新的gmarker(点);
map.addoverlay(标记);
marker.openinfowindowhtml(地址);
}
}
;
}
showAddress('此处有一些地址')
}
$('body').ready(初始化);
$(‘body’)卸载(枪弹);
& /脚本& GT;
< /代码> <起源。

代码:
<div id="map_canvas" class="grid_8 omega" style="width:460px; height: 420px"></div>
<script src="http://maps.google.com/maps?file=api&v=3&sensor=true&key=my-key-is-here" type="text/javascript"></script>
<script type="text/javascript">
function initialize() {
if (GBrowserIsCompatible()) {
var map = new GMap2(document.getElementById("map_canvas"));
map.setCenter(new GLatLng(52.229676, 21.012229), 13);
map.setMapType(G_HYBRID_MAP);
map.setUIToDefault();
}
var geocoder = new GClientGeocoder();
function showAddress(address) {
geocoder.getLatLng(address, function(point) {
if (!point) {
alert('Nie można znaleÅºÄ adresu: '+address);
} else {
map.setCenter(point, 13);
var marker = new GMarker(point);
map.addOverlay(marker);
marker.openInfoWindowHtml(address);
}
}
);
}
showAddress('some address goes here')
}
$('body').ready(initialize);
$('body').unload(GUnload);
</script>