Skip to:
Content
Pages
Categories
Search
Top
Bottom

Still get some /members/ links with BP_ENABLE_ROOT_PROFILES


  • peterverkooijen
    Participant

    @peterverkooijen

    I use this in the config.php to remove /members/ from member URLs in version 1.1.3:

    define( 'BP_ENABLE_ROOT_PROFILES', true );

    Works nicely and looks good.

    But /members/ still pops up in a few links, including for example in the Sitewide Activity feed. I tried to trace back to the code that produces that link, but get lost…:

    sitewide-activity.php -> function bp_activity_content -> bp-activity-templatetags.php -> $activities_template->full_name ????

    A search on /members/ did not bring up anything usefull. It’s probably MEMBERS_SLUG+username or something like that.

    Anyone know where the code is that produces the name link in the Sitewide Activity feed? Was this an already reported bug and is there a fix?

Viewing 7 replies - 1 through 7 (of 7 total)

  • r-a-y
    Keymaster

    @r-a-y

    Old activity items will indeed have the old “/members” URLs.

    The way I see it is you have two ways around this:

    1) Redirect old member URLs to their new profile root URLs in /.htaccess.

    2) Modify activity contents directly from the database.


    peterverkooijen
    Participant

    @peterverkooijen

    OK, so this will resolve itself with new items? I can live with that.

    Thanks r-a-y!


    r-a-y
    Keymaster

    @r-a-y

    To redirect your old member URLs, try putting the following line in .htaccess:

    RedirectMatch 301 ^/members/(.*)$ http://example.com/$1

    Change example.com to your site.

    This goes right above the following line in .htaccess:

    # add a trailing slash to /wp-admin


    peterverkooijen
    Participant

    @peterverkooijen

    Cool, another trick that could come in handy in other situations. Thanks again!


    r-a-y
    Keymaster

    @r-a-y

    I think the above code is for a subdirectory MU install.

    If you’re using a subdomain MU install, let me know and I’ll modify the above code.


    Walid
    Participant

    @walid3

    hello :) well the last thing you mentioned goes exactly for me, I use MU subdomains and enabled root_profiles, I did this before even installation, but now my admin profile leads to
    ” The page you were looking for was not found. “
    that happen when I try to visit it through ” http://example.com/admin/ ” new members okay but admin only is messed up, so is there a code to fix it? and would it affect me site forward?


    Walid
    Participant

    @walid3

    any help for my question?

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Still get some /members/ links with BP_ENABLE_ROOT_PROFILES’ is closed to new replies.
Skip to toolbar