Skip to content

Instantly share code, notes, and snippets.

@klhall1987
Last active July 4, 2020 09:38
Show Gist options
  • Save klhall1987/cd9c30676f76df0c1124043a3993b51b to your computer and use it in GitHub Desktop.
Save klhall1987/cd9c30676f76df0c1124043a3993b51b to your computer and use it in GitHub Desktop.
ninja-forms-submission-permissions.php
<?php
// Must use all three filters for this to work properly.
add_filter( 'ninja_forms_admin_parent_menu_capabilities', 'nf_subs_capabilities' ); // Parent Menu
add_filter( 'ninja_forms_admin_all_forms_capabilities', 'nf_subs_capabilities' ); // Forms Submenu
add_filter( 'ninja_forms_admin_submissions_capabilities', 'nf_subs_capabilities' ); // Submissions Submenu
function nf_subs_capabilities( $cap ) {
return 'edit_posts'; // EDIT: User Capability
}
@mmichealjroberts
Copy link

@iwebnetid Anywhere in functions, or require it from a specialist filters.php - as normal essentially as long as it ultimately is required in functions.php

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment