Starting from plugin version 4.8.0 of Download Monitor, you can easily remove the plugin version information from the meta section by attaching to a filter in your child theme’s functions.php
file. This simple customization allows you to enhance the security and privacy of your website by not exposing the plugin version to potential attackers.
Here’s how to remove the plugin version from the meta using the dlm_hide_meta_version
filter:
Step 1: Access Your WordPress Dashboard
Log in to your WordPress dashboard.
Step 2: Locate Your Child Theme’s functions.php
File
In order to apply this customization, you’ll need to access and edit your child theme’s functions.php
file. If you’re not using a child theme, it’s strongly recommended to create one to preserve your customizations during plugin and theme updates.
Navigate to your child theme’s directory. You can typically find this under wp-content/themes/your-child-theme/
.
Step 3: Edit the functions.php
File
Open the functions.php
file in a code editor of your choice.
Step 4: Add the Filter Function
Inside the functions.php
file, add the following code snippet at the end:
// Remove DLM Plugin Version from Meta
function remove_dlm_plugin_version() {
return true;
}
add_filter( 'dlm_hide_meta_version', 'remove_dlm_plugin_version' );
This code snippet defines a custom function remove_dlm_plugin_version
that returns true
for the dlm_hide_meta_version
filter, effectively removing the plugin version from the meta.
Step 5: Save the File
Save the functions.php
file after adding the code.
Step 6: Verify the Change
To verify that the plugin version is no longer displayed in the meta section, visit a page on your website where Download Monitor is active and has a download displayed. The meta information for the download should no longer show the plugin version.
By following these steps, you’ve successfully removed the plugin version from the meta in the Download Monitor plugin, starting from version 4.8.0. This small customization helps improve the security and privacy of your WordPress website by concealing sensitive information from potential attackers.
Please note that when updating the Download Monitor plugin in the future, your customization will remain intact since it’s placed in your child theme’s functions.php
file.