• Resolved seg

    (@seg)


    Hi, I am using v2.7 and in the Admin under Posts I noticed the “Mail Subscribers” feature. Is there an easy way to disable this or restrict it to all Roles except the Administrator?

Viewing 7 replies - 1 through 7 (of 7 total)
  • must be one of your plugins adds that – does it have a configuration section?
    Likely only an admin sees that link

    Thread Starter seg

    (@seg)

    Currently my Admin does not display “Mail Subscribers” for Subscriber or Contributer, but Author and above shows “Mail Subscribers”. Is this the default set-up?

    I would like to restrict Author and below from using this feature or remove it all together. I could try to use the Role Manager plug-in to manipulate the role levels or create a custom role to replace Author, but before trying that I was just curious if there is an easier way.

    Thread Starter seg

    (@seg)

    I experimented with this more using the Role Manager. The ability to Mail Subscribers seems to be attached to the Publish Posts capability. If you can’t publish a post then you can’t mail a subscriber. If anyone else has any ideas please let me know. Thanks!

    Thread Starter seg

    (@seg)

    Just an update – this is a feature of the Subscribe2 plug-in, not part of the main WordPress install. Unfortunately the plug-in doesn’t provide any settings to turn this off. I am going to try and manually adjust the plugin – at least I don’t have to change any WP core files!

    Thread Starter seg

    (@seg)

    One last note for anyone who wants to know how to fix this. I used the Role Manager plug-in and created a new Capability called Mail Subscribers. In the Subscribe2 plug-in file (subscribe2.php) on line 245 I changed the parameter “publish_posts” to “mail_subscribers”. The final version looks like this:

    add_submenu_page('post-new.php', __('Mail Subscribers', 'subscribe2'), __('Mail Subscribers', 'subscribe2'), "mail_subscribers", __FILE__, array(&$this, 'write_menu'));

    Now I can pick which roles have the ability to Mail Subscribers. Hope this helps someone out there!

    mrsixcount

    (@mrsixcount)

    as an update the line has moved to 124 in the “Hook the menu” section. Where do you edit the mail_subscribers option in the users profile?

    mrsixcount

    (@mrsixcount)

    Ok found this. If you put this on in the hook section it will setup the administrator and editor to have access. Otherwise you can put it in a spot and deactivate and activate the plugin to have it run once.
    Note: Author role is ‘author’

    // Set ‘mail_subscribers’ Capabilities To Administrators and Editors
    $role = get_role(‘administrator’);
    if(!$role->has_cap(‘mail_subscribers’)) {
    $role->add_cap(‘mail_subscribers’);
    }
    $role = get_role(‘editor’);
    if(!$role->has_cap(‘mail_subscribers’)) {
    $role->add_cap(‘mail_subscribers’);
    }

    Thanks again for the help. I hope this helps others as well.

Viewing 7 replies - 1 through 7 (of 7 total)

The topic ‘Disable Mail Subscribers’ is closed to new replies.