Home Forums Newsletter Plugin Support Editors can't access to Newsletter (404)

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #10850
    PODxt
    Participant

    Hi, I’m trying to let editors use Newsletter. In configuration / Advanced settings / Enable access to blog editors? is set to Yes.

    But when I login with an editor account, the newsletter menu is displayed but when I click on menu items I’m getting a 404 error.

    Note that my editor role has been … edited with Advanced Access Manager plugin so some menus like “Welcome” “Configuration” or “Diagnostic” don’t show in the editor user menu.

    Is there a way to fix this?
    Thanks

    #10851
    PODxt
    Participant

    After 2 hours of fiddling around options, let me rephrase my request: what I would like to do is hide menus like “Welcome” “Configuration” or “Diagnostic” so they don’t show in the editor user menu. When I try to do so with the Advanced Access Manager plugin, it gives me the 404 error.

    When I try to hide these menus with a function like remove_menu_page(‘newsletter_main_index’);
    It hides all the Newsletter pages for the user instead of hiding only the Welcome page.

    How can I hide some menu items so people don’t mess too much around with Newsletter? I want them to only see “Newsletters” “Suscribers” and “Statistics” in their menus.
    Thanks

    #10852
    PODxt
    Participant

    I tried adding the following code to functions.php (following this thread http://wordpress.stackexchange.com/questions/95837/remove-a-menu-item-created-by-a-plugin ) to no avail :

    function ns_remove_admin_menus() {
    global $menu;
    global $current_user;
    if ($current_user->ID != 1) {
    remove_submenu_page( “admin.php”, “admin.php?page=newsletter_main_index” );
    remove_submenu_page( “admin.php”, “admin.php?page=newsletter_main_main” );
    }
    }
    add_action(‘admin_init’, ‘ns_remove_admin_menus’, 999 );

    #10855
    Stefano
    Keymaster

    Probably you should remove only the page slug:

    newsletter_main_index

    not the url.

    #10859
    PODxt
    Participant

    Hi Stefano, i tried with
    remove_submenu_page( “admin.php”, “newsletter_main_index” );
    remove_submenu_page( ‘admin.php’, ‘newsletter_main_index’ );
    remove_submenu_page( ‘newsletter_main_index’, ” );
    remove_submenu_page( ‘newsletter_main_index’, ‘admin.php’ );

    with no luck, your input is apreciated

    #10860
    PODxt
    Participant

    Got it working with remove_submenu_page( “newsletter_main_index”, “newsletter_main_index” );

Viewing 6 posts - 1 through 6 (of 6 total)
  • You must be logged in to reply to this topic.