Divi没有在加载时弹出标记的选项,但您可以这样做:
打开文件divi\\includes\\builder\\scripts\\frontend-builder-scripts.js
查找此项:
google.maps.event.addListener(marker, \'click\', function() {
if( infowindow_active ) {
infowindow_active.close();
}
infowindow_active = infowindow;
infowindow.open( $this_map_container.data(\'map\'), marker );
});
}
});
}
并替换为:
google.maps.event.addListener(marker, \'click\', function() {
if( infowindow_active ) {
infowindow_active.close();
}
infowindow_active = infowindow;
infowindow.open( $this_map_container.data(\'map\'), marker );
});
infowindow.open( $this_map_container.data(\'map\'), marker );
}
});
}
现在,地图pin将加载打开。
请记住,这是核心修改,在更新主题时需要记住。