Skip to content

Instantly share code, notes, and snippets.

@gcorne
Created December 10, 2012 18:01
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gcorne/4252178 to your computer and use it in GitHub Desktop.
Save gcorne/4252178 to your computer and use it in GitHub Desktop.
Hide Jetpack menu from Subscribers
<?php
function jetpack_hide_from_subscribers() {
if ( ! current_user_can('edit_posts') ) {
remove_menu_page( 'jetpack' );
}
}
add_action('jetpack_admin_menu', 'jetpack_hide_from_subscribers');
@josuch
Copy link

josuch commented Feb 4, 2014

I found this code on wordpress.org. You said: "To install, I would create a file in mu-plugins named jetpack-tweaks.php and add the code. While there is a chance that this tweak could break after an upgrade, it is unlikely and won't negatively impact your site" What is mu when you say mu-plugins? And can this be placed in the functions php file instead? If not could you be more specific as to where to place it?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment