Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
WordPress: security measures for functions.php
<?php
/*
* Disable version information from being displayed in the header or RSS feed
*
* Sources:
* http://torquemag.io/2016/06/keep-your-wordpress-site-safe-with-these-four-tips/
*/
function disable_version_info() {
return '';
}
add_filter('the_generator', 'disable_version_info');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment