Skip to content

Instantly share code, notes, and snippets.

@Archie22is
Last active November 2, 2015 08:30
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Archie22is/653c1fc1dba4ad4ad3cd to your computer and use it in GitHub Desktop.
Save Archie22is/653c1fc1dba4ad4ad3cd to your computer and use it in GitHub Desktop.
Hide Pods Admin Menu from non-adminitrators
<?php
// add the following script to your theme functions.php
// Archie22is ---> https://github.com/Archie22is
add_action('admin_menu', 'remove_pods_menu', 11);
function remove_pods_menu () {
get_currentuserinfo() ;
global $user_level;
if ($user_level < 10){
define('PODS_DISABLE_ADMIN_MENU', true);
define('PODS_DISABLE_CONTENT_MENU', true);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment