hupe13 / extensions-leaflet-map-github

WordPress Plugin Extensions for Leaflet Map - Github Version
GNU General Public License v2.0
13 stars 2 forks source link

Function [cluster] not working after upgrading from 3.5.8 to 4.0 #12

Closed julianzz98 closed 7 months ago

julianzz98 commented 7 months ago

First of all, thank you for your work and providing this great plugin to the community!

After I manually updated the plugin from version 3.5.8 to 4.0, the function [cluster] seems to be not working anymore. I tried different configurations using the provided options with no results.

The code in my HTML element looks like this (formatted and modified the content for readability):

[leaflet-map lat=51.1657 lng=10.4515 zoom=6 width=800px height=800px]
[leaflet-geojson src="path/to/example.json"]<b>Example:</b> {Example}<br> [/leaflet-geojson]
[hover geojsontooltip="{Test}"]
[cluster]
[zoomhomemap]

Are there any changes that I am missing? The changelog did not mention direct changes to [cluster] function.

Would appreciate a response!

hupe13 commented 7 months ago

I can't confirm this. Maybe the zoom is to high, zoom out the map. Do the marker cluster then? Or set you disableClusteringAtZoom = 0? Then is clustering forbidden.

julianzz98 commented 7 months ago

The clustering is not happening, regardless of the zoom level. disableClusteringAtZoom = 0 is not set. Next step would be to manually downgrade the plugin, for this I still need to increase the file size limit...

julianzz98 commented 7 months ago

Okay after manually downgrading to the previous version (GitHub ZIP), the cluster function is working again.

Version 3.5.8: image

Version 4.0: image

julianzz98 commented 7 months ago

Could the PHP version cause a problem? We are still using 7.4, even though the requirements of the plugin state PHP version 7.4 ...

hupe13 commented 7 months ago

php 7.4 is old, you should upgrade. But this seems not the problem. Install https://de.wordpress.org/plugins/query-monitor/ to see any errors. Open the developer console to see Javascript or other errors. Maybe the geojson file has a problem. Keine Ahnung. My mail address.

julianzz98 commented 7 months ago

Danke! Will report back.

hupe13 commented 7 months ago

Or a cache plugin?

julianzz98 commented 7 months ago

Moin! I finally had the chance to upgrade the PHP version from 7.4 to 8.3 and reinstalled the plugin in the version 4.0. The cluster function now works again.

Therefore I would suggest you pinpoint the current minimum requirement of the PHP version that the plugin needs now and update your listed requirements accordingly.

Closing this issue! Thanks again for the response!

hupe13 commented 7 months ago

Thank you for testing. I no longer have access to php 7.4 anywhere, so I installed it on my local PC (Windows) again and only called up one page and it didn't give any error. That's why the php 7.4 error would have been interesting for me.

julianzz98 commented 7 months ago

That is my bad. Forgot about checking the error message beforehand...

hupe13 commented 7 months ago

There are compatibility checks available. These show problems with php 7.2 or earlier, but no problems with 7.4. Aber egal, schön, dass es nun läuft und auch aktuell ist.

hupe13 commented 7 months ago

Ich habe soeben einen (diesen) Bug gefunden.

julianzz98 commented 7 months ago

Und? Was war jetzt der Fehler?

hupe13 commented 7 months ago

Ich habe Parameter als "string" statt als "int" der Funktion übergeben. Ich hatte doch was geändert von 3.5.8 zu 4.0: Ich habe versucht, das Inline-Javascript auszulagern.

julianzz98 commented 7 months ago

Ok, dann hat sich das ja fix gelöst! Danke für den tollen Support!

hupe13 commented 7 months ago

Na wenn 2 sich beschweren ... Und dort hatte ich auch einen Link zur Seite, das hilft.