Plugin Directory

WP Hide Dashboard

Q. How do I change this to hide the dashboard and tools menu and help options from other roles besides Subscriber?

A. To hide these from other roles, you will need to edit the plugin in a plain text editor and make the following changes:

  • Subscriber -> Contributor: Change !current_user_can('edit_posts') to !current_user_can('upload_files')
  • Subscriber -> Author: Change !current_user_can('edit_posts') to !current_user_can('create_users')
  • Subscriber -> Editor: Change !current_user_can('edit_posts') to !current_user_can('manage_options')

There are 3 instances of this code in the plugin (lines 52, 67, and 83 in version 1.4) - make sure you change all of them.

Q. Will you be creating an admin option page to allow specifying what role we want to hide these from?

A. I have this on the to-do list for the plugin, and am working on it for a future release. In the meantime, you will still need to edit the plugin manually to change the role.

Download

FYI

Compatibility beta

Your Setup

Log in to vote.

The Consensus (2 reporting)

50%
100,1,1
100,1,1
100,1,1
100,1,1
100,1,1
100,1,1
100,1,1
100,1,1
100,1,1
100,1,1
100,1,1
100,1,1
100,6,6
50,2,1
100,1,1

Average Rating

5 stars
4 stars
3 stars
2 stars
1 star
(16 ratings)