Created
August 29, 2014 06:16
-
-
Save chillybin/8b8a23873822591ce07a to your computer and use it in GitHub Desktop.
This file contains hidden or 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
<?php | |
// pulled from https://github.com/billerickson/BE-Genesis-Child | |
// reposition inpost metabox | |
remove_action( 'admin_menu', 'genesis_add_inpost_layout_box' ); | |
add_action( 'admin_menu', 'be_add_inpost_layout_box' ); | |
function be_add_inpost_layout_box() { | |
if ( ! current_theme_supports( 'genesis-inpost-layouts' ) ) | |
return; | |
foreach ( (array) get_post_types( array( 'public' => true ) ) as $type ) { | |
if ( post_type_supports( $type, 'genesis-layouts' ) ) | |
add_meta_box( 'genesis_inpost_layout_box', __( 'Layout Settings', 'genesis' ), 'genesis_inpost_layout_box', $type, 'normal', 'default' ); | |
} | |
} | |
// Reposition inpost SEO metabox | |
remove_action( 'admin_menu', 'genesis_add_inpost_seo_box' ); | |
add_action( 'admin_menu', 'be_add_inpost_seo_box' ); | |
function be_add_inpost_seo_box() { | |
if ( genesis_detect_seo_plugins() ) | |
return; | |
foreach ( (array) get_post_types( array( 'public' => true ) ) as $type ) { | |
if ( post_type_supports( $type, 'genesis-seo' ) ) | |
add_meta_box( 'genesis_inpost_seo_box', __( 'Theme SEO Settings', 'genesis' ), 'genesis_inpost_seo_box', $type, 'normal', 'default' ); | |
} | |
} | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment