在Android设备上显示融合表层吗?
根据此链接http://lumlei.blogspot.com/2015/06/waste-map-with-selector-base-map-not.html,融合表分层地图正确显示地图图标和基本地图名称。但是当在Android设备(5.0)上查看博客站点时,基本地图无法显示城镇名称。
这是我的博客网站上的html代码(来自Molle博士的调试代码):
<html>
<head>
<style>
#map-canvas img{
padding: 0;
background: transparent;
border: none;
-moz-box-shadow: none;
-webkit-box-shadow: none;
box-shadow: none;
}
#map-canvas { width:500px; height:400px; }
.layer-wizard-search-label { font-family: sans-serif };
</style>
<script src="http://maps.google.com/maps/api/js?sensor=false" type="text/javascript">
</script>
<script type="text/javascript">
var map;
var layer_0;
function initialize() {
map = new google.maps.Map(document.getElementById('map-canvas'), {
center: new google.maps.LatLng(21.15533458599919, 106.11318745800781),
zoom: 10,
mapTypeId: google.maps.MapTypeId.ROADMAP
});
layer_0 = new google.maps.FusionTablesLayer({
query: {
select: "col1",
from: "1ah3uh2UaH-z4PCVJ4gJr3nww3qBg3oBFd_ZeB0VD"
},
map: map,
styleId: 2,
templateId: 2
});
}
function changeMap_0() {
var whereClause;
var searchString = document.getElementById('search-string_0').value.replace(/'/g, "\\'");
if (searchString != '--Select--') {
whereClause = "'Treatment' = '" + searchString + "'";
}
layer_0.setOptions({
query: {
select: "col1",
from: "1ah3uh2UaH-z4PCVJ4gJr3nww3qBg3oBFd_ZeB0VD",
where: whereClause
}
});
}
google.maps.event.addDomListener(window, 'load', initialize);
</script>
</head>
<body>
<div id="map-canvas">
</div>
<div style="margin-top: 10px;">
<label class="layer-wizard-search-label">
Edit map view here >
<select id="search-string_0" onchange="changeMap_0(this.value);">
<option value="--Select--">--Select--</option>
<option value="Active">Active</option>
<option value="Building">Building</option>
<option value="None">None</option>
</select>
</label>
</div>
</body>
</html>