【发布时间】:2013-07-11 12:20:22
【问题描述】:
如何从 Json 文件中过滤 gmap 标记?
$(函数(){ 演示.add(函数(){ $('#map_canvas').gmap({'disableDefaultUI':false, 'callback': function() { 变种自我=这个; $.getJSON('demo.asp', 函数(数据){ $.each(data.markers, function(i, marker) { self.addMarker({ 'position': new google.maps.LatLng(marker.latitude, marker.longitude), 'bounds':true } ).click(function() { self.openInfoWindow({ 'content': marker.content }, this); }); }); }); }}); })。加载(); });【问题讨论】:
标签: json google-maps