You may need to change all the icons used in the plugin. To allow that, the plugin provides a hook that you can use to change them by your custom icons.
- Open the plugin folder (“nearby-map”) on your computer.
- Within, you’ll find a folder named “img”. Copy that folder in your computer. Within, you’ll find all the default icons used in the plugin.
- Replace the icon(s) that you want to change by your custom icon(s) in the folder you just copied in your computer. Please note that you MUST save your new icon(s) with the same name of the default icon(s), otherwise, it won’t be recognized and no icon can be displayed instead! Note also that you MUST NOT change the name of any subfolder within the folder “img” nor the location of an icon.
- Once you’re done replacing the default icons, upload your folder somewhere in your server.
- Open your theme’s file “functions.php”, copy and paste the following code:
function csnm_replace_plugin_icons($default_icons_folder){
/**
* Replace "THE_URL_TO_YOUR_FOLDER" by the full URL to ...
* your custom icons folder in your server.
* e.g. "http://yourwebsite.com/images/" */
$custom_icons_folder = "THE_URL_TO_YOUR_FOLDER";
$handle = @fopen($custom_icons_folder, 'r');
if(!$handle)
return $default_icons_folder;
else return trailingslashit($custom_icons_folder);
}
add_filter('csnm_img_file', 'csnm_replace_plugin_icons', 10, 1);