How to Allow Editors to Edit Gravity Forms

PluginsTechnical ElementsWebsite ContentWordPress
gravity forms logo

We frequently instruct clients to try to keep the number of users with administrator-level access to a minimum. Not everyone who will be editing site content needs to also have access to all the plugins, such as Gravity Forms, and settings, nor should they.

The problem is that by default, giving more limited access to users, such as the Editor role, limits them to accessing the standard content: Posts and Pages. But almost all websites have kinds of content that is edited outside of these two areas. What about pop ups or forms?

Pretty much without exception, we use Gravity Forms on our WordPress websites. We love the extendability and dozens of integrations: HubSpot, MailChimp, Zapier, PayPal, Stripe, and many more. But if a user is only an Editor, they aren’t going to be able to edit forms on their site. There’s no need to get an admin involved just to make an update to a form, so we update some code in order to get form editing back where it belongs – in the hands of the content editor.

In order to make this happen, add the following code to your child theme’s functions.php file:

/* make gravity forms available to Editor role */
function add_gf_cap()
{
    $role = get_role( 'editor' );
    $role->add_cap( 'gform_full_access' );
}
 
add_action( 'admin_init', 'add_gf_cap' );

Happy form editing!

Ready to boost productivity and engage customers? Our expert team creates reliable, user-friendly apps for all platforms. Let’s get started—contact us today!

Frequently Asked Questions

Why can’t WordPress Editors edit Gravity Forms by default?

By default, WordPress restricts access to certain settings and plugins based on user roles. Editors can manage content like posts and pages, but they do not have access to plugins or advanced settings such as Gravity Forms. This limitation is designed to keep sensitive settings controlled by administrators.

How can I allow WordPress Editors to edit Gravity Forms?

To allow Editors to manage Gravity Forms, you need to add specific permissions to their role. This can be done by adding a custom code snippet to the functions.php file of your child theme. The snippet grants Editors the capability to access and edit all forms.

What does the code do?

The provided code snippet adds the gform_full_access capability to the Editor role. This allows Editors to access and edit Gravity Forms without giving them full administrative rights to other settings and plugins on the site.

Can I use this code for other roles besides Editors?

Yes, you can modify the code to apply to other user roles. For example, if you want another role (like Author or Contributor) to have form editing access, you can replace it 'editor' with the role you want to modify in the code.

What happens if I remove the code from functions.php?

If you remove the code from your functions.php file, the changes will be reverted, and the Editor role will no longer have access to Gravity Forms. They will be restricted to the default permissions for their role.

Share: