Skip to content

Instantly share code, notes, and snippets.

@fugudesign
Last active November 15, 2016 13:23
Show Gist options
  • Save fugudesign/e55cc203bb9bda4511c496ef4d6a1f13 to your computer and use it in GitHub Desktop.
Save fugudesign/e55cc203bb9bda4511c496ef4d6a1f13 to your computer and use it in GitHub Desktop.
Wordpress remove unnecessary code from <head>
// Remove unnecessary code from header
remove_action( 'wp_head', 'wp_generator' );
remove_action( 'wp_head', 'rsd_link' );
remove_action( 'wp_head', 'wlwmanifest_link');
remove_action( 'wp_head', 'wp_shortlink_wp_head');
// and also for WPML
global $sitepress;
remove_action( 'wp_head', array( $sitepress, 'meta_generator_tag' ) );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment