Hi,
the check for icons is based on the file readme-icons.txt in the marker icons folder (usually /wp-content/uploads/leaflet-maps-marker-icons/) – if this readme-file is not there, this warning is displayed.
ad Shadow url warning: might be due to the fact that your site is not visible for public yet. Please try for testing purposes to make your site available for a short time to see if this message is not visible anymore (which I guess)
regards,
Robert
Hi Robert
Thanks for the fast reply. the file is there with this content. I cant make it visible. because the domain name does not exist. Its just a spoof to build the website and from there transfer to the real location.
i can even access the file on my system and open it by its link.
can you please add the ability to turn off those messages? I wont want them all the time in my backend.
thank you !!!
Leaflet Maps Marker plugin uses map icons from the Maps Icons Collection by Nicolas Mollet (http://mapicons.nicolasmollet.com/).
By default, a preselection of about 100 icons (from more than 700 available icons) has been added to the plugin.
On first activation of the plugin, the zip-file mapicons.zip gets unzipped into the directory \wp-content\uploads\leaflet-maps-marker-icons
of your WordPress installation (note: you might have to enter your ftp-credentials once depending on your configuration)
If you want to add more map icons, please download the desired icons from http://mapicons.nicolasmollet.com/
and upload them to the directory \wp-content\uploads\leaflet-maps-marker-icons
PLEASE DO NOT DELETE THIS FILE FROM YOUR MARKER ICONS DIRECTORY AS IT IS USED TO CHECK IF INSTALLATION WAS SUCCESSFUL!
Hi
you are using curl to check if the fileexists. Why not just use the php fileexists function like you do in the admin header.php?
if ( ! file_exists(LEAFLET_PLUGIN_ICONS_DIR . DIRECTORY_SEPARATOR . ‘readme-icons.txt’) ) {}
Best regards,
BackuPs
This solves the issue.
$shadow_icon_url_exists = file_exists(LEAFLET_PLUGIN_ICONS_DIR . DIRECTORY_SEPARATOR . ‘readme-icons.txt’);
Best regards,
BackuPs
Hi
i think i see the issue here. You are cheching for the marker-shadow.png in the plugin folder and reporting the wrong message for the shadow-url.
it did set me completely on the wrong track.
the %1 is reporting this (http://thewebsite.com/wp-content/uploads/leaflet-maps-marker-icons)
whereas it should be reporting
http://thewebsite.com/wp-content/plugins/leaflet-maps-marker/leaflet-dist/images
see the compatibility-check.php
Best regards,
BackuPs
Hi
if you set the check for the marker-shadow to
$shadow_icon_url= WP_PLUGIN_DIR .’/leaflet-maps-marker/leaflet-dist/images/marker-shadow.png’;
you can use the
$shadow_icon_url_exists = file_exists($shadow_icon_url);
and you dont need curl to acces that file.
however the error message still does not match the actual file-check. I did not adjust that
Best regards,
BackuPs
Hmm that does not work when the user sets its own shadow icon….. brr
ok i will remove the check in my spoof site only.
Thanks for settings me in the right direction.
It leaves you with the wrong error message the %1 to fix.
have a nice day.
Hi,
thanks for analyzing – will check your suggestions.
ad file_exists: this doesnt work for urls as far as I know and only for paths on server.
Anyway: I will add an option to disable admin notices completely in the next release…
regards,
Robert
Hi Robert,
sorry for the spamming. It was my analysing process. Thanks for adding the option. I already grasped that the file_exist did not work because of the url-path which can be added in the option.
But what if they dont have curl installed? i dont know if the get_headers function will be a better solution.
Thanks anyway.
have a great weekend for whats left of it.
No need to excuse – this is no spamming for me – appreciate your infos.
If not curl is installed, the check wont be executed. I already implemented this fall back solution with the latest release. I did quite a lot research and found the curl approach with checking for http status 200 the most efficient one for my solution.
Ad get_headers: cant remember if I also checked this one. It seems that this would also work, but according to http://php.net/manual/de/function.get-headers.php (comment #2) this would be the slowest solution…
best regards,
Robert