ZenphotoCMS Forum
zp_OpenStreetMap: Blank space - Printable Version

+- ZenphotoCMS Forum (https://forum.zenphoto.org)
+-- Forum: Support (https://forum.zenphoto.org/forum-1.html)
+--- Forum: Plugins (https://forum.zenphoto.org/forum-6.html)
+--- Thread: zp_OpenStreetMap: Blank space (/thread-12601.html)



zp_OpenStreetMap: Blank space - HermannG - 16-10-2016

I tried a lot to get zp_OSM working following the instructions on github. Unfortunately, I did not have success for 2 weeks. I tried several themes (especially basic and libratus), put the printOpenStreetMap() in image.php (hopefully in the right place).
There is obviously some space reserved below the picture, but no map displayed (only blank background).

I could not find any errors in the logs, so I ask here for advice, maybe someone has a suitable "image.php" I can try with.

Thanks for any help
Hermann




zp_OpenStreetMap: Blank space - fretzl - 16-10-2016

Some obvious questions ;-)
Is the plugin properly installed?(does it show up in the list of plugins?)
Did you in fact activate/enable the plugin?
Do you have a link to the site?

Can you post the code you placed + some surrounding lines of code?




zp_OpenStreetMap: Blank space - HermannG - 16-10-2016

Hi fretzl, thanks for the quick reply.

Is the plugin properly installed?(does it show up in the list of plugins?)
--> Yes

Did you in fact activate/enable the plugin?
--> Yes, the box on the plugins list is ticked.

Do you have a link to the site?
--> Unfortunately not now, I'm using a virtual machine for testing.

Can you post the code you placed + some surrounding lines of code?
--> Here comes a snippet from libratus' image.php (about lines 63-81):

`

`




zp_OpenStreetMap: Blank space - fretzl - 16-10-2016

Thanks!
About the installation of the plugin again: Is the folder [i]zp_openstreetmap[/i] present in the [i]/plugins[/i] folder?




zp_OpenStreetMap: Blank space - acrylian - 16-10-2016

You actually you don't need to check for geodata as the class method printMap() does this already, ,too. (counts for both plugins).

Actually using the printOpenStreetMap() and optionally setting the parameters are needed should be enough. Setting the options everytime is not needed at all as you can set them on the backend.

I heard reports about the map not showing up but so far I could not reproduce it. Make sure you have selected one of the OSM map tiles for testing. And of course there is not a big company behind OSM so sometimse their servers take a while.




zp_OpenStreetMap: Blank space - HermannG - 26-10-2016

Hi everyone,
since I could not figure out what caused the problem, I did a fresh install on a real machine (not a virtual one), and everything is working perfectly.
So thank you very much for the support; I hope I can help at anoter place.




zp_OpenStreetMap: Blank space - acrylian - 27-10-2016

Thanks for the feedback. Great it worked out finally. I hope I find time update the plugin to the latest leafletjs script soon.