好的,我可以弹出信息窗口并显示我的链接(实际上称为“地址”)但是我不能让它显示为信息窗口中的链接。我试过在地址字段周围放置无济于事。数据显然进入了信息窗口,我无法将其设为链接?
downloadUrl("http://xxxxxxxxxxxxxxxxxxxxxxxxxxxx.php", function(data) {
var xml = data.responseXML;
var markers = xml.documentElement.getElementsByTagName("marker");
for (var i = 0; i < markers.length; i++) {
var name = markers[i].getAttribute("name");
var address = markers[i].getAttribute("address");
var type = markers[i].getAttribute("type");
var point = new google.maps.LatLng(
parseFloat(markers[i].getAttribute("lat")),
parseFloat(markers[i].getAttribute("lng"))
);
var html = "<b>" + name + "</b> <br/>" + "address"; x x x x x x x x
var icon = customIcons[type] || {};
var marker = new google.maps.Marker({
map: map,
position: point,
icon: icon.icon,
shadow: icon.shadow
});
bindInfoWindow(marker, map, infoWindow, html);
}
}