Community Events conflict with AJAX

Home Forums Calendar Products Community Events Community Events conflict with AJAX

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #28581
    Todd
    Participant

    Hi. I have TEC Community Events installed on a site that also uses the bbPress plugin to provide a Discussion Forum on the site. In the bbPress forum, a user can click a link to “Favorite” a topic, or “Subscribe” to a topic. These links use AJAX. And after much research, I found that (for reasons I don’t understand, as i’m not a plugin developer) a plugin that uses ajax might actually be hitting an ADMIN url, called admin-ajax.php. And bbPress (v2.2.2) does this, in bbPress/templates/default/bbpress-functions.php, line #198 (php code modified just to make it display here )
    var ajaxurl = (php start) echo admin_url( ‘admin-ajax.php’ ); (php end) ;

    The problem is…. Community Events has a setting to BLOCK ACCESS to WordPress Admin, based on the user’s Role (a great feature!). BUT when the user’s Role is blocked from the WP Admin, he is also blocked from the admin-ajax.php url, so the ajax Favorite and Subscribe links in bbPress fail.

    Any insight much appreciated.
    -Todd

    #28584
    Todd
    Participant

    I actually just resolved this problem for myself. Here’s what I did, in case others have this issue.

    In Admin > Events > Settings > Community > Access Control, I UNchecked the “Block access to WordPress Admin” (and have all “Roles to block” UNchecked. So I disabled this feature from TEC/CE. And instead, I used the plugin “WP Block Admin” to handle this. It allows me to block my front-end users from the WP backend, based on a Capability (that you can specify), without actually blocking the ajax links (in my bbPress) that call to wp-admin/admin-ajax.php.

    @TEC/CE DEVS — Please consider this approach in a future update.

    #28590
    Casey
    Participant

    Todd,
    Thanks for reaching out and glad to hear you got everything sorted out. I’m closing out this thread, but feel free to start a new one if you have further issues. Thanks!

    #978232
    Support Droid
    Keymaster

    This topic has not been active for quite some time and will now be closed.

    If you still need assistance please simply open a new topic (linking to this one if necessary)
    and one of the team will be only too happy to help.

Viewing 4 posts - 1 through 4 (of 4 total)
  • The topic ‘Community Events conflict with AJAX’ is closed to new replies.