0
下面你可以看到,我的代码显示在地图和标记(从JSON):Adsense的使用jQuery UI的地图
$('#map_canvas').gmap().bind('init', function() {
$.getJSON('../js/locate.php', function(data) {
$.each(data.markers, function(i, marker) {
var mapvalue=new google.maps.LatLng(marker.latitude, marker.longitude);
$('#map_canvas').gmap('addMarker', {
'tags': [''+marker.category+''],
'position': mapvalue,
'bounds': true,
'icon':'../images/'+marker.category+'.png',
'animation':google.maps.Animation.DROP
}).click(function() {
$('#map_canvas').gmap('openInfoWindow', { 'content': ''+marker.category+'<BR><div id="cust_content"></div>' }, this);
setTimeout("opencust(\'" +marker.id+"\');",100);
});
});
});
});
我怎么能在我的地图,新的AdSense脚本:https://developers.google.com/maps/documentation/javascript/advertising#AdvertisingAdUnit
感谢您的帮助!
什么是你想在这里做什么? – insomiac 2012-07-17 02:22:52
我只是想在我的地图上添加AdSense广告。谷歌脚本很容易,但我找不到与jquery-ui-map库一起使用它的方法。 – user1522790 2012-07-17 06:24:36