• Resolved njali909

    (@njali909)


    Hello Support,

    I want to remove menu page pho tonic for other user roles?
    I am not able to remove with below code:

    remove_menu_page( ‘photonic-getting-started’ );

    Can you help me to do that?

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Sayontan Sinha

    (@sayontan)

    I don’t think you should try to do anything here.

    The top-level menu has 5 sub-menu pages (Settings, Getting Started, Authentication, Shortcode Replacement, and Helpers).

    1. If your user does not have admin privileges, Photonic will automatically remove the “Settings” and “Authentication” pages.
    2. If your user has the capability to edit posts, they must see the other menu pages (“Getting Started”, “Shortcode Replacement” and “Helpers”).
    3. If your user is just a regular subscriber and does not have any capability to edit anything on your site, Photonic will automatically remove all menu items.
    Thread Starter njali909

    (@njali909)

    Hello Support,

    No. 2 match with my requirement.
    But I want to hide photonic in second case.
    How can I do that?

    Plugin Author Sayontan Sinha

    (@sayontan)

    I don’t understand why you want to remove a help page that does not have any settings.

    Anyway, your code is correct. You just need to place it in the correct hook. Make sure you go through WP documentation for it (https://developer.www.ads-software.com/reference/functions/remove_menu_page/)

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Remove menu page’ is closed to new replies.