Created
August 22, 2013 12:01
-
-
Save PhilippSchreiber/6306312 to your computer and use it in GitHub Desktop.
wpSEO: Deactivate for some post types
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
add_filter( 'wpseo_add_meta_boxes', 'prefix_wpseo_add_meta_boxes ); | |
function prefix_wpseo_add_meta_boxes() { | |
global $post; | |
$post_types_without_seo = array( 'date', 'slide', 'video' ); | |
return !in_array( get_post_type($post), $post_types_without_seo); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment