You can use the do_meta_boxes
hook to remove the metaboxes instead.
Like below
add_action( 'do_meta_boxes', 'vpm_remove_meta_box' );
function vpm_remove_meta_box() {
remove_meta_box( 'ortext-metabox', 'post', 'normal' );
remove_meta_box( 'ez-toc', 'post', 'normal' );
}
See this for more info
https://developer.wordpress.org/reference/functions/remove_meta_box/
Related Posts:
- How to only hook on Single.php after content?
- Change Page’s Tag Using functions.php File
- What characters are allowed as a shortcode tag and how should they be sanitized?
- Edit plugin without hooks in functions.php
- How to remove filter added by another plugin in a class
- Using add_filter inside another class
- Add custom meta box on Post page
- Hide WordPress Plugin Deactivation Links
- Alter post slug by a filter that is fired just after a post is created
- Pass A Value From Outside To A Plugin Variable
- Does the ‘nav_menu_css_class’ filter accept 2 or 3 arguments?
- Very stubborn wp_register_script / add_action vs remove
- do_action and hook methods
- Remove action from a plugin class, forced to use global instance
- ElasticPress how to Include Meta to the mapping?
- remove filter which calls a public static function
- Determine plugin name from within plugin_action_links filter
- Admin Dashboard with Custom Tab for Client
- Reposition Woocommerce Message
- Security checking in meta_box save is reluctant?
- How to remove xmlns on language_attributes()?
- How to modify shortcode attributes with data from current post
- add_filter comment_edit_redirect not working
- Is there a filter for get_post_custom()?
- Can I hook into get_avatar to supply a hash instead of an email?
- dynamically generating plugin syntax
- How do action and filter hooks understand where to look for the core function that we hooked our function to them
- How to append to title via functions.php for auto-posting plugin [duplicate]
- Edit default comments page in WP Admin
- Creating a plugin to sanitize comment and the url field before display only
- Modifying the comments section through a plugin regardless of theme
- Save / Show multi line text in metabox
- Passing an array from shortcode-function to filter-function
- Get Time Taken By Each Action Hook in WordPress
- External Script Using WP – Hooks / Actions Not Working?
- Retrieving Meta from Image Attachment
- WordPress metaboxes – textfield suggestion automatically populated
- add_filter doesn’t work
- Using add_action before add_filter on a plugin?
- Check if variable is set in filter
- Passing stored variables to add_filter
- Modify page title and subtitle with a plugin
- override filter in a plugin
- remove_action not removing add_action from constructor
- Date format – Meta Box plugin
- Trying to add a page template for my custom post type from a plugin, but it will not display in the template dropdown unless file is in theme
- Access post title from custom meta box on title change
- Inserting Plugins Into Blank Space of Externally Designed WordPress Theme
- Add a function call after content automatically?
- How to add filter for wordpress plugin?
- How to use add_action for multiple instances of the same class
- How to Use the Filter “sidebar_login_widget_form_args”
- WordPress meta-box and checkbox-list
- is there a way to pass a parameter to a add_menu_page function?
- How to hook into action/filter call
- Edit post image attributes on fly?
- Error Metabox Warning: call_user_func() expects parameter 1 to be a valid callback
- Excluding specific post from custom next/previous theme function
- Add hook after content without formatting
- Preset custom fields
- Unpublished Pages Failing To Appear On Custom Path
- Adding an item to an anonymous array inside a filter?
- How to get checkbox by default true in metabox?
- WooCommerce Product Table – filter query on attributes
- Does having apply_filters in the middle of an array make a difference?
- Disable WC Bookings automatic order completion [closed]
- Plugin function in child theme
- How to pass multiple custom fields as shortcode’s parameters
- Modify function output in a plugin
- CMB2 Output Select Box Chosen Option
- Override filter variable not working
- Add Cancel Button to a Custom Meta Box
- Remove action added in plugin class from theme
- Show custom taxonomy in theme
- Using multi-dimensional array with filter
- WordPress CPT Url metabox collection
- Help needed with woocommerce (wc stripe) filter
- Add_Meta_box to custom page (formidable edit post)
- why my wordpress dont have toolbar like, plugin, themes and other?
- CMB2 Post Search Field displays/repeats initial post if left empty
- Why can’t I shove an instance of a class into a variable from a do_action hook?
- Add custom field for users
- Passing a parameter to filter and action functions
- How to add jquery to my custom post type wp plugin
- passing ‘&’ in return function of add_filter
- Filter for modifying image on upload
- Adding a Filter to Sidbar Login Plugin to Change Login Button Lable
- Strip shortcode from excerpt [duplicate]
- Problem for recover and save metaboxes
- County Finder form/plugin?
- Simply Exclude – Category feed exclusion is excluding from category feed instead of just the main feed
- How to change response of admin-ajax request?
- add query string to all pages after user logged in
- WordPress plugin add_filter returning a link does not work. What is the correct way?
- Order shipped by which driver[hook for woocoomerce order staus changed and popup in admin panel ] [closed]
- iframe not showing on frontend when using a CMB2 field
- Unable to pass arguments from plugin form to filter hook using ajax, the data is transferring via ajax but unable to pass as arguments in filter hooks
- How often should I execute add_filter and function declaration in Code Snippets?
- Meta box not displaying on the plugin page
- Selectively override Easy Digital Downloads protection via filter