Skip to:
Content
Pages
Categories
Search
Top
Bottom

Link for page that display groups you are a member of

  • @danceyrselfclean_admin

    Participant

    Hi I am trying to create a custom link in the admin menu that links to the page containing the list of groups you are a member of, for example http://www.DOMAIN.co.uk/members/USER/groups/

    Here is the code I am using to add the admin menu link, minus the actual URL which is the part I need some assistance with.

    add_action( 'admin_menu' , 'admin_menu_lsb1' );
    function admin_menu_lsb1() {
        global $menu;
        $menu[9990] = array( __('My Groups'), 'read', 'URL', 'function', 'open-if-no-js menu-top', '', 'dashicons-admin-generic' );
    }

    From what I have read I think I need to incorporate bp_core_get_username($user_id) into the URL but I can’t seem to figure it out, PHP just isn’t my strong point.

    If anyone could offer assistance I would greatly appreciate it.

Viewing 1 replies (of 1 total)
  • @osisis

    Participant

    Not sure if you have worked this out on your own as of yet, but if not you could try the code at this link. Sorry, BP.org keeps blocking the code from posting it in here.

    Paste Bin Add My Groups to AdminBar

Viewing 1 replies (of 1 total)
  • The topic ‘Link for page that display groups you are a member of’ is closed to new replies.
Skip to toolbar