WordPress.org

Forums

Constant Contact for WordPress
Trouble getting plugin to work in Editor role (18 posts)

  1. wyclef
    Member
    Posted 3 years ago #

    Constant Contact plugin is working great for Admin but it's not working in editor role. I keep getting a constant-contact-api cannot be found error. I tried using the menu editor plugin to change the permissions to editor, and manage_comments, and publish_posts... but nothing works. Thoughts?

    http://wordpress.org/extend/plugins/constant-contact-api/

  2. wyclef
    Member
    Posted 3 years ago #

    i'm wondering if this plugin has user roles built into it that aren't being overridden by other plugins?

  3. wyclef
    Member
    Posted 3 years ago #

    specifically 'Cannot load constant-contact-api.' in editor role. really could use some help getting this to work for editor.

  4. RogerWheatley
    Member
    Posted 3 years ago #

    I have the same identical issue!

    I've searched all over, but am unable to find an answer.

    Side note: Looks like we may just terminate Constant Contact and use another service instead. (At least that's where the discussion is heading at this end).

  5. RogerWheatley
    Member
    Posted 3 years ago #

    @wyclef - I think there must be user roles built in? But, with the short time I've been given, I can't find then.

  6. RogerWheatley
    Member
    Posted 3 years ago #

    I tried the following to change permissions, however, I'm still getting the error when using the Editor account:

    Editing files:

    • functions.php
    • events.php
    • constant-analytics.php
    • widget-form-designer.php
    • form-designer.php

    Search for:

    current_user_can

    Change the option (for "current_user_can") to be equal to some option (such as edit_others_posts). The syntax would be some example like this:

    current_user_can('manage_options')

    changed to this:

    current_user_can('edit_others_posts')

    It almost seems like there is some other hard coding we're not yet aware of. I just wish the developer was available to provide a comment so that we could try and effect the needed capability.

  7. Zack Katz
    Member
    Plugin Author

    Posted 3 years ago #

    For events.php, list_users is the required role.
    For the widget, it's install_plugins
    Everything else, it's manage_options

    Am I hearing that you prefer integration with the Members plugin?

  8. RogerWheatley
    Member
    Posted 3 years ago #

    Hi Zack

    Thanks.

    The plugin does not work with the Editor role. (When the editors log into wp-admin, they cannot access the Constant Contact options).

    So... I edited the plugin files (as above) and changed "manage_options" to "edit_others_posts" (which Editors can do). However, when Editors select the option, they are displayed the cannot load Constant Contact API message.

    What is the proper way for me to enable Constant contact options to be accessible to the Editor role and higher, when logged into wp-admin?

    [The Members plugin didn't work (for this scenario) as this pertained to content, not to the ability to access the Constant Contact options in wp-admin]

    Again... Thank you!!

    Addendum:

    I just checked and the following plugins are in use:

  9. RogerWheatley
    Member
    Posted 3 years ago #

    @Zack

    I took another look at your suggested plugin. You're correct after all. ;)

    Yes!

    Can this work with Constant Contact on the back end, to allow an Editor (or other defined role) to configure the Constant Contact options in the wp-admin dashboard?

    Thanks!

  10. RogerWheatley
    Member
    Posted 3 years ago #

    @Zack

    Okay, something just is not working.

    I installed Members and made sure that I enabled the following capabilities to the Editors:

    • manage_options
    • list_users
    • install_plugins

    As these are the permissions I found when searching for "current_user_can", within all Constant Contact plugin files.

    Constant Analytics displayed in the Dashboard for Editors, but Constant Contact (and options) did not.

    I used Admin Menu Editor so that the Constant Contact link would appear in the Dashboard for Editors - Now it does.

    But when I click the link (logged in as an Editor) I get an error message that says: Cannot load constant-contact-api.

    Please let me know what can I do to get this working?
    Thanks!

  11. wyclef
    Member
    Posted 3 years ago #

    do a multi-file search for 'administrator'. change what you want for editor to 'moderate_comments'. a bit of a hack but worked for me. i needed a fix pronto.

  12. RogerWheatley
    Member
    Posted 3 years ago #

    @wyclef.

    Thanks, I just finished that, but it does not seem to work at my end. I Still get that "cannot load" (Constant Contact API) error. :(

  13. wyclef
    Member
    Posted 3 years ago #

    which files did you change?

  14. RogerWheatley
    Member
    Posted 3 years ago #

    @wyclef

    There were only three files with the word "administrator".

    constant-analytics.php -edited
    menu.php - edited
    form-designer.php - edited.

    Changing "administrator" to "editor" did not provide a fix.

    Also, when searching for files with the word "administrator"; returned three files that did NOT specify user capabilities (except for constant-analytics.php), as such, there was no where to replace permissions with "moderate_comments"

    However, I searched for "current_user_can" and was able to modify several files, changing permissions to "moderate_comments" - But it did not work at this end.

    Those files were:

    • functions.php
    • events.php
    • constant-analytics.php
    • widget-form-designer.php
    • form-designer.php

    What are your thoughts?
    Thanks muchly...

  15. wyclef
    Member
    Posted 3 years ago #

    well, i didn't bother with the form-designer stuff as I am not using that but changing administrator to editor also did not work for me. i changed administrator to moderate_comments and that did work.

  16. nickwanhere
    Member
    Posted 3 years ago #

    hey guys,

    1. Please install the plugin Members for easier role capability management.
    2. Then go to constant-contact-apo/admin/menu.php

    3. you need to look for add_menu_page and add_submenu_page
    the word administrator should really be a capability instead. So if you give your editor can manage_options, replace the administrator with manage_options

    Hope it helps!

  17. RogerWheatley
    Member
    Posted 3 years ago #

    @nickwanhere

    Thanks, I'll try that (the response is a tich hard to follow), so will actually log into wp-admin and then read your post again.

    One thing... Where is "constant-contact-apo/admin/menu.php" - I looked at the Constant Contact menu many times and there's nothing referring to APO (that I could readily find) - Maybe I'm just misunderstanding something?

    Thanks!

  18. Alaskan
    Member
    Posted 3 years ago #

    I'm trying to figure out the exact same thing, and I can't follow nicks' last post, either. Did you have any luck, Roger?

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Constant Contact for WordPress
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic