Created
December 30, 2021 18:48
-
-
Save markbosky/0af1a0a6bb9e51c60bb537d7f226bdce to your computer and use it in GitHub Desktop.
WordPress - Remove Comments Menu from Admin Area
This file contains 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
/** | |
* Removes comments from the left hand navigation in the admin. | |
*/ | |
add_action( 'admin_menu', 'wp_remove_menus' ); | |
function wp_remove_menus() { | |
global $menu; | |
global $submenu; | |
remove_menu_page( 'edit-comments.php' ); | |
echo ''; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment