Skip to:
Content
Pages
Categories
Search
Top
Bottom

Create different pages with different parameters for bp_has_group()

  • @clementkjhjkh

    Participant

    Hi,
    I currently have the default groups directory page which display all the groups.
    I would like to create an other page which will call the group_loop but with a parameter in the function bp_has_group().
    So i want two pages, both display the list of the groups but one only display groups which match the bp_has_group() parameter.

    My question is how can i create such a page.

    I hope i made myself understood
    Thanks

Viewing 3 replies - 1 through 3 (of 3 total)
  • @modemlooper

    Moderator

    Use WordPress a page template and hard code a BuddyPress group loop in the page template. Create a WordPress page in the admin. You do the same thing when you created those pages when you install BuddyPress. BuddyPress just overrides the page that gets loaded with it’s own template which is why you don’t have to create the page template yourself.

    @clementkjhjkh

    Participant

    Thanks,
    it worls perfectly but now i have some trouble using parameters for bp_has_group
    I want to display only the groups which match the condition ‘my_slug’==’yes’
    I tried :

    Is it the correct syntax ?

    Thanks a lot

    @modemlooper

    Moderator

    `
    `

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Create different pages with different parameters for bp_has_group()’ is closed to new replies.
Skip to toolbar