Hi Stephen
I’ve just updated to the latest version of Visual Composer and the event_map shortcode has started playing up. When I move the map around, the new tiles don’t load at the edges. If I zoom in and out it’s fine. This is an example page with a native VC Google Map block and an event_map shortcode for comparison.
http://www.myeloma.org.uk/playground/test-page-by-stoo/
I’ve put in a ticket with the VC guys too.
Hope you can help
Cheers
Stu
Stuart Farish
Hi Stuart,
That page doesn’t appear to have a map on it?
Also, if two plug-ins are loading a map on the same page that might cause issues with one of the plug-ins as it’s likely two copies of Google maps API is being loaded onto the page.
If its the case that only Event Organiser is displaying a map, but with VC installed there are still issues it could be that VC is loading the Google maps API (in addition to Event Organiser doing so).
Stephen Harris
Sorry about that. The page is now visible.
Stuart Farish
Hi Stephen. I contacted the VC devs and they said their plugin couldn’t be the problem! Not hugely helpful.
Is there a way I can temporarily stop EO loading the Google maps API? At least I could test the idea that it’s two copies of Google maps API.
Cheers
Stu
Stuart Farish
Hi Stuart,
Looking into this I couldn’t see the normal ‘Google maps being loaded twice’ error that I could see – in fact it appears they are embedding a map using an iframe.
I don’t see how they can conclude their plug-in might not be in some reasonable, from what you’ve suggested it works with the theme disabled and it worked before an update.
If they could give some indication of what changes were made that might identify the problem. But currently my only observation is that they are loading JavaScript on every page (including this plug-in) and not just when they need it to display the map, so I wonder if they only loaded files when they needed it it might not conflict with Event Organiser’s map.
It’s possible to ‘deregister’ the google maps API script, but as per my earlier comments, I’m not sure it well help
Stephen Harris
Hi Stephen
Found the issue. Turns out it was CSS related. My theme was setting:
img {
max-width:100%
}
for the main content block.
Adding :
.googlemap img {
max-width: none;
}
fixes the problem.
Nothing to do with EO.
Cheers
Stu
Stuart Farish
Glad that’s sorted, thanks for reporting back!
Stephen Harris