I’ve added some POIs programmatically to the map in two ways.
In the first case, I’ve created a map object and added POIs there, and called display() funtion directly to display the map.
In the second case, I’ve hooked a custom function to ‘mappress_map_display’ action and added POIs there, and used the shortcode to display the map.
Showing the first map, map is zoomed correctly (map automatically contains all POIs).
Regarding the second map, map is not zoomed (a world map is shown).
I want to zoom the map correctly in the second case.
I really can’t say, since it depends on your custom code. Are you sure it’s necessary to use custom code for this? It seems like you could just display a mashup with the additional 3 locations included from a map attached to a post.
I can tell you that in general the map won’t autozoom/center if you provide a center or zoom parameter.
Custom code is necessary for me.
I use Mappress with user management plugin. Every users have address custom field, and I want to show a map with all users which address is assigned to POI.
So the first case works fine, I could gave up the second case.