PHP: Remove WordPress Version String

Old way of removing WP version string, I’m using a more contemporary (and complete) solution. I’ll post it in another entry.


remove_action('wp_head', 'wp_generator');

// Remove Windows Live Writer link in header
// Do Not do this if you use it
remove_action('wp_head', 'wlwmanifest_link');
remove_action('wp_head', 'rsd_link');

// Remove WP version info
function hide_wp_vers()
 return null;
} // end hide_wp_vers function



This goes to functions.php in your theme directory. Although, I would use a more recent solution because this one isn’t very complete. As I say, will post the solution I’m using in a new entry.

Leave a Reply

Your email address will not be published. Required fields are marked *