Google maps API center and zoom multiple markers
问题 I know there are lots of questions answered on this subject but I can't get them to work with my code. I have used code from this question here but my javascript knowledge is limited and I can't work out where to put it to get it to work. I am using multiple locations which are dynamically added from a wp query and I want the map to automatically find the center of all the locations and preferable zoom to the extent of all the markers. This is my code to generate the map: var map = new google