Allow passing false for the meta_box_cb arg in register_taxonomy() to turn off the meta box display entirely. fixes #21543.

git-svn-id: https://develop.svn.wordpress.org/trunk@25948 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Helen Hou-Sandi
2013-10-27 16:28:19 +00:00
parent 6af7557201
commit b2e15261ba
2 changed files with 6 additions and 3 deletions
+2 -1
View File
@@ -157,7 +157,8 @@ foreach ( get_object_taxonomies( $post ) as $tax_name ) {
else
$tax_meta_box_id = $tax_name . 'div';
add_meta_box( $tax_meta_box_id, $label, $taxonomy->meta_box_cb, null, 'side', 'core', array( 'taxonomy' => $tax_name ) );
if ( false !== $taxonomy->meta_box_cb )
add_meta_box( $tax_meta_box_id, $label, $taxonomy->meta_box_cb, null, 'side', 'core', array( 'taxonomy' => $tax_name ) );
}
if ( post_type_supports($post_type, 'page-attributes') )