Last active
March 14, 2023 22:50
-
-
Save stephanieleary/c37e7be3e97ab7a8eeea70398c1b93a8 to your computer and use it in GitHub Desktop.
Specify meta boxes that should be hidden by default for new users.
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 | |
add_filter( 'default_hidden_meta_boxes', 'custom_default_hidden_screen_options', 10, 2 ); | |
function custom_default_hidden_screen_options( $hidden, $screen ) { | |
$hide_these = array( | |
'dashboard_primary', | |
'postcustom', | |
'trackbacksdiv', | |
); | |
return array_merge( $hidden, $hide_these ); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment