Skip to:

Opened 4 years ago

Last modified 12 days ago

#3355 new defect (bug)

Forum Pagination links are broken

Reported by: sirlouen's profile SirLouen Owned by:
Milestone: Awaiting Review Priority: normal
Severity: normal Version:
Component: General Keywords: needs-patch


I posted this issue in buddypress trac some weeks ago:

I've found that forum pagination links are broken:
Check this user for example:
In the bottom pagination links:

But they commented that it could be an issue on bbpress

Change History (7)

#1 @SirLouen
4 years ago

  • Keywords needs-patch added

#2 @jgasba
13 days ago

Bumping this issue as I noticed the same thing and I'm retracing that breadcrumb. BuddyPress + bbpress combo produces broken pagination links on members profiles.

Anything new on this 4 years old issue?

#3 @jgasba
13 days ago

@johnjamesjacoby marked the issue n°2190 as resolved 11 years ago here through fix [4741]

The issue is still there.
Tested today with BuddyPress 11.4 and 12.0.0-beta4 combined with bbPress 2.6.9 (WordPress 4.6.1)

Bug was reported also on BuddyPress trac but I'm pretty confident this is a bbpress issue

Last edited 13 days ago by jgasba (previous) (diff)

#4 @jgasba
13 days ago

From what I managed to gather not knowing the bbpress code until now, I think the bug comes from
bbp_get_replies_pagination_base() in /includes/replies/template.php (for replies, equivalent for topics being bbp_get_topics_pagination_base)

// User's replies
if ( bbp_is_single_user_replies() )
    $base = bbp_get_user_replies_created_url( bbp_get_displayed_user_id() );
    // returns exampledomain/membres/username/forums/responses/
// Root profile page
} elseif ( bbp_is_single_user() ) {
    $base = bbp_get_user_profile_url( bbp_get_displayed_user_id() );
    // returns exampledomain/membres/username/

When using BuddyPress the function used in an other user profile is bbp_is_single_user for the pagination links so the pagination link url does not include /forum/responses/

The solution might be in one of those functions. I guess.

#5 @Robin W
12 days ago

I'm not quite clear what you are saying - only because I don't have need of buddypress, so don't know what it us looking for :-)

from the 2 functions above, which function needs to return what different answer?

#6 @jgasba
12 days ago

On a WordPress install using BuddyPress+bbPress if you navigate to a user profile page and look at his forum history, the pagination links are :


when they should be, for replies tab as an example:


For a reason I'm not too sure to understand, when both plugins are enabled bbPress does not recognize the replies tab of a user profile as bbp_is_single_user_replies == true. This returns false and then the query does not return the proper output.

11 years ago it was resolved apparently on bbPress end but the template.php code has changed since and the issue is back again. See this issue from back then

On the logged in user profile, on /forums/replies bbp_is_single_user() and bbp_is_single_user_replies return true but on another user profile bbp_is_single_user() returns true when bbp_is_single_user_replies returns false.

I can't figure out why. I have notified buddypress too as the bug is affecting even their own website. I think it possibly affects a lot of website using both plugins together.

#7 @Robin W
12 days ago

thanks for prompt further info - I'm not a bbpress author, but try to help out. I'll take a further look at this shortly :-)

Note: See TracTickets for help on using tickets.