Beekeepersblog logo

Back

Contact Form 7 WordPress plugin image icon

Hide Contact-Form-7 to other users from WordPress Dashboard [updated 2019]

Contact Form 7

By Default the Contact-Form-7 in the WordPress Dashboard is visible to all the users. You can control this by adding a little code in your wp-config.php file. There are two options of codes.

  1. Option 1: Show the contact form but hide the options
  2. Option 2: Hide the contact form from the WordPress sidebar

Option 1

This option will show the form, so the other use can see the form and its shortcode in the main table. But when they try to access the form a message will display on the page. You are not allowed to edit this contact form.

Copy and paste this code in your wp-config.php file in your WordPress root directory.

/* Show the form but hide the options - Contact-Form-7 */
define( 'WPCF7_ADMIN_READ_WRITE_CAPABILITY', 'manage_options' );

/* That's all, stop editing! Happy blogging. */
Contact-form-7 plugin page - image
Figure 1: Screenshot of Contact-Form-7 plugin page that cannot be accessed by another user.

Option 2

To hide the Contact-Form-7 from the WordPress side menubar to other users, Use this code. When the user login into the WordPress dashboard they will not see Contact-Form-7 from the sidebar.

/* Hide the form from the Dashboard - Contact Form 7 */
define( 'WPCF7_ADMIN_READ_CAPABILITY', 'manage_options' );

/* That's all, stop editing! Happy blogging. */
Contact-form-7 is hidden from the dashboard - image
Figure 2: Screenshot of WordPress dashboard with hidden Contact-Form-7 menu for other users.
How do you like this article?
OkGoodHelpful!Very Helpful!Awesome!!   Is the article helpful?
Loading...