我有一个 gmap 气球。
var marker = createMarker(point, '<div style="width:240px" id="mapsball"><h2>Splash of London</h2><img src="_assets/images/themes/shop.jpg" id="mapThumb" width="100" align="right" /><p>110-112 Hoxton Street</p><p>London</p><p>N1 6SH</p></div>');
map.addOverlay(marker, icon);
和附加到图像的点击事件('#mapsball')的脸框,它在脸框中打开它
$(function() {
$("body").delegate("#mapThumb", "click", function(){
jQuery.facebox('<img src="_assets/images/themes/shop.jpg" align="right"/>');
});
});
这在 ff 和 safari 和 chrome 中运行良好。但不会在ie中开火。我在 ie 中没有收到 js 错误,所以我假设它只是没有被绑定。任何帮助将不胜感激。
我还尝试了以下但结果相同:
if (map.isLoaded()){
$(function() {
$("body").delegate("#mapThumb", "click", function(){
jQuery.facebox('<img src="_assets/images/themes/shop.jpg" align="right" />');
});
});
}