Skip to:

Group API in BP 1.2 – double slashes in component url

  • D Cartwright


    Hi there,

    Both of the plugins I’ve released recently suffer from this problem and I haven’t found a way to fix it.

    Basically, in the slug for the group component you get a double-slash rather than single. So it would be:

    rather than

    If you manually delete one of the slashes the page still loads correctly… I’m really not sure what’s causing it.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Show us the code. How are you creating the URL?

    D Cartwright


    Hi Paul,

    The full code is in this (small) plugin here:

    The url is created with the following code:

    class Group_Activity_Subscription extends BP_Group_Extension {

    function group_activity_subscription() {
    global $bp;

    $this->name = 'Notifications';
    $this->slug = 'notifications';

    // Only enable the notifications nav item if the user is a member of the group
    if ( groups_is_user_member( $bp->loggedin_user->id , $bp->groups->current_group->id ) ) {
    $this->enable_nav_item = true;
    } else {
    $this->enable_nav_item = false;

    $this->nav_item_position = 91;

    $this->enable_create_step = false;
    $this->enable_edit_item = false;

    add_action ( 'wp_print_styles' , array( &$this , 'add_settings_stylesheet' ) );


    Peter Anselmo


    I can confirm this behavior with a completely different group extension plugin. The page still works, but there are two slashes before the specific page.

    D Cartwright


    Ah, thanks for this input. I wasn’t sure if it was just me going mad or something :)

    If nobody chimes in with something that shows us both as just missing something obvious I’ll post a ticket in trac.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Group API in BP 1.2 – double slashes in component url’ is closed to new replies.
Skip to toolbar