Remove Yoast SEO stuff from edit screen columns

Posted in: Newspaper
Post count: 9544

In case anybody needs this, I found the Yoast SEO plugin stuff intrusions into my post index admin screens super annoying.

Code to filter that to not happen. (Add to your functions.php file or custom plugin):

/*** FILTER TO REMOVE COLUMNS FROM YOAST SEO ***/

/* Remove Yoast SEO Columns
* Credit: Andrew Norcross http://andrewnorcross.com/
* Last Tested: Jul 06 2017 using Yoast SEO 5.0 on WordPress 4.8
*
* If you have custom post types, you can add additional lines in this format
* add_filter( 'manage_edit-{$post_type}_columns', 'custom_remove_yseo_columns', 10, 1 );
* replacing {$post_type} with the name of the custom post type.
*/
add_filter( 'manage_edit-post_columns', 'yoast_seo_admin_remove_columns', 10, 1 );
add_filter( 'manage_edit-page_columns', 'yoast_seo_admin_remove_columns', 10, 1 );
function yoast_seo_admin_remove_columns( $columns ) {
unset($columns['wpseo-score']);
unset($columns['wpseo-score-readability']);
unset($columns['wpseo-title']);
unset($columns['wpseo-metadesc']);
unset($columns['wpseo-focuskw']);
unset($columns['wpseo-links']);
unset($columns['wpseo-linked']);
return $columns;
}

  • This topic was modified 9 years by simchris.
  • This topic was modified 9 years by simchris.
Post count: 20688

Hi,

This is useful to have if you don’t want the SEO columns appearing in the post index screen options. Thank you Chris for providing this code, I am sure some will find it very helpful indeed.

Thanks

Viewing 2 posts - 1 through 2 (of 2 total)
The forum ‘Newspaper’ is closed to new topics and replies.