Skip to:
Content
Pages
Categories
Search
Top
Bottom

Redirect Loop on Ajax Actions in Custom Loop


  • Andrew Tibbetts
    Participant

    @andrewgtibbetts

    I am using a page template for my “front page” so that if a user is logged out they see the “sign up” side of the site and when logged in an activity feed.
    I used the example loop here:

    https://codex.buddypress.org/developer/loops-reference/the-activity-stream-loop/

    When I click ‘Favorite’, unlike on the /member/username/ activity feed where it instantly ajaxes between ‘Favorite’ and ‘Remove Favorite’, it tries loading the action /activity/favorite/123/?_wpnonce=asdf1234 and then the redirect loop error kicks in.

    Ideas?

Viewing 1 replies (of 1 total)

  • modemlooper
    Moderator

    @modemlooper

    I would use code examples from the core plugin and not copy from codex, sometimes that can be off slightly. the javascript might not be loading for this page. In your page template you can call the activity loop with

    <?php bp_get_template_part( 'activity', 'index' ); ?>

    Another option is to have the activity page as the front page and then swap out the templates if not logged in.

Viewing 1 replies (of 1 total)
  • The topic ‘Redirect Loop on Ajax Actions in Custom Loop’ is closed to new replies.
Skip to toolbar