How to Hide WordPress version
November 29, 2008 · Print This Article
In order to secure your blog, is it a good thing to hide the meta version appearing within the and html tag of your blog.
Since WP 2.5, the version is inserted automatically, and can’t be removed as easily at before. Except if you use that hack !
This hack isn’t hard to do at all. Just open the functions.php file from your theme and add the following line of code:
remove_action('wp_head', 'wp_generator');
On the above code, We just used the remove_action to remove the wp_generator() function, which prints out WP version. As that function will now not be executed, the WordPress version will not be visible from your source code, and potential hackers will never know which version you are using.




















Comments
Got something to say?
You must be logged in to post a comment.