Support » Plugin: bbp style pack » User can’t view their profile

  • Resolved Chuckie

    (@ajtruckle)


    I am confused. I have one particular user:

    Role: Subscriber
    Forum Role: Participant

    As an admin I can view his profile. But he can’t.

    In bbp style pack – profiles I have:

    “Show only users own profile”

    and

    “Allow moderators to see all profiles”

    So they should be able to see their profile.

    If I create a test account it works. But his account refuses to let him see his own profile. He has purged his cache and tried different browsers. I have also tried to view his profile using his login credentials.

    It will not work.

Viewing 8 replies - 1 through 8 (of 8 total)
  • Plugin Author Robin W

    (@robin-w)

    ok so as a test deactivate style pack and recheck, that will tell you whether the error is in bbpress or style pack

    Good idea. Just tried on my staging site.

    If I deactivate bbp style pack then I can view “my” “TestUser3” profile. When I activate bbp style pack I can’t view it and it stays on the home page.

    Plugin Author Robin W

    (@robin-w)

    ok, very limited on my availability – any chance you can change code in my plugin and test for me

    so

    includes/functions.php

    starting line 1440

    change

    $current_url = $_SERVER['REQUEST_URI'];
    		$current_username = wp_get_current_user()->user_login ;
    		if (strpos($current_url,$current_username)==true) $test=true ;

    to

    $current_url = $_SERVER['REQUEST_URI'];
    		$current_user_id = wp_get_current_user()->ID ;
    		$current_username = bbp_get_user_nicename( $current_user_id )
    		if (strpos($current_url,$current_username)==true) $test=true ;

    save and retest

    If that works, I’ll release it as next version

    • This reply was modified 1 month, 2 weeks ago by Robin W.

    That seems to work to me!

    🙂

    Plugin Author Robin W

    (@robin-w)

    great – I’ll release in the next couple of days – leave the code in, my update will just overwrite it – thanks for testing

    You are welcome.

    One thing – one of the lines was missing the ; character.

Viewing 8 replies - 1 through 8 (of 8 total)
  • You must be logged in to reply to this topic.