Join the social network of Tech Nerds, increase skill rank, get work, manage projects...
 
  • How to remove parent metabox in wordpress child theme

    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 0
    • 213
    Comment on it

    Hello Everyone, today I guide you to remove parent metabox in WordPress child theme.


    You can use remove_meta_box() function for removing parent theme metabox in WordPress child theme.
    Put the below code into your child theme functions.php file.
    Suppose, In parent theme videoURL is default metabox and we want to remove this in their child theme.

    <?php
    
    add_action( 'admin_menu' , 'pinboard_remove_metaboxes', 99 );
    
    function pinboard_remove_metaboxes() {
    
        remove_meta_box( 'videoURL', 'post', 'normal' );
        remove_meta_box( 'parent_video_url_metabox', 'post', 'normal' );
    }
    ?>
    

 0 Comment(s)

Sign In
                           OR                           
                           OR                           
Register

Sign up using

                           OR                           
Forgot Password
Fill out the form below and instructions to reset your password will be emailed to you:
Reset Password
Fill out the form below and reset your password: