当前位置: 动力学知识库 > 问答 > 编程问答 >

Disable "Add User" functionality from backend in Wordpress

问题描述:

How can I disable creating user from backend. I want all the users to be registered from front end registration form (I am using Pie Register Plugin for registration), There should not be an option to "Add User" in wp-admin area even for admin.

How do I do that? some custom code.

网友答案:

In functions.php add the following:

add_action('admin_menu', 'remove_menus');
function remove_menus()
{
    global $submenu;
    remove_submenu_page ('users.php', 'user-new.php');    //Dashboard->Updates
}
分享给朋友:
您可能感兴趣的文章:
随机阅读: