Make plugin useable by authors
-
Hi,
How can I allow the plugin to be used by author role in WordPress?
Following code worked for me, that authors were able to create/delete feeds and manage the settings however, they could not edit the feeds.
Which permission/capability should be granted to them?I don’t want to give them the manage_options capability because that would be too much.
add_menu_page(__( 'Product Feed PRO for WooCommerce', 'woo-product-feed-pro' ), __( 'Product Feed Pro','woo-product-feed-pro' ), apply_filters( 'woosea_user_cap', 'edit_posts' ), __FILE__, 'woosea_generate_pages', esc_url( WOOCOMMERCESEA_PLUGIN_URL . '/images/icon-16x16.png'),99); add_submenu_page(__FILE__, __( 'Feed configuration', 'woo-product-feed-pro' ), __( 'Create feed', 'woo-product-feed-pro' ), apply_filters( 'woosea_user_cap', 'edit_posts' ), __FILE__, 'woosea_generate_pages'); add_submenu_page(__FILE__, __( 'Manage feeds', 'woo-product-feed-pro' ), __( 'Manage feeds', 'woo-product-feed-pro' ), apply_filters( 'woosea_user_cap', 'edit_posts' ), 'woosea_manage_feed', 'woosea_manage_feed'); add_submenu_page(__FILE__, __( 'Settings', 'woo-product-feed-pro' ), __( 'Settings', 'woo-product-feed-pro' ), apply_filters( 'woosea_user_cap', 'edit_posts' ), 'woosea_manage_settings', 'woosea_manage_settings');
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘Make plugin useable by authors’ is closed to new replies.