Skip to:
Content
Pages
Categories
Search
Top
Bottom

Filterable member directory via profile fields.

  • @lindsayannb

    Member

    I actually thought this was a core feature, but I guess I was wrong.

    My website is going to rely heavily on the fact that members will sign up so that they could be listed in the members directory. The goal is to create a community of professionals who can use each other’s services when the need arises instead of going to an outside company.

    I have set up custom profile fields and have one field that has a list of options and check boxes. What I would love to do is use those options as user categories – essentially filtering members by them.

    I know that this is partially completed using the Custom Profile Fields Filter which allows me to set specific profile fields as “clickable” tags that the user can utilize to find people who answered that field the same.

    So I have the ability to link to all profiles with OPTION1 selected but what I would need help with is how to create a menu on the member directory page that lists all options for this field and clicking them would bring you to a list of all members with that option selected.

    It seems like it would be easy, but looking in the codex all I could find were functions regarding groups and very little regarding profiles and profile fields.

    Thanks in advance!

Viewing 2 replies - 1 through 2 (of 2 total)
  • @chrisclayton

    Participant

    @Lindsayannb – Essentially what you would want to do is utilise the built in “search_terms” parameter (which your already using for the profile fields links) and modifying the searchterm based on what is selected via the dropdown menu – https://codex.buddypress.org/developer-docs/custom-buddypress-loops/the-members-loop/

    Haven’t looked indepth into this specific loop yet, (and i’m not sure if it will work on a directory page) but their is a profile field loop which might help… (https://codex.buddypress.org/developer-docs/custom-buddypress-loops/the-profile-data-loop-bp_has_profile/)

    @lindsayannb

    Member

    Ahhh “search_terms” Is what I was missing. I was looking for the “fields” which would only yield the contents of the profile fields correct?

    Would I really need to use a loop? Doesn’t the search_terms inherently search all profiles with that term and display the search terms page?

    I mean all I would need to do is display all search terms as links (just as they would display on a profile page) in a navigation bar on the member directory.

    Another way to do this would be if you can allow people to use tags in the signup form. Essentially all I am looking for is some type of taxonomy I can use for members that the members set for themselves. I am not married to the idea of using the search_terms.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Filterable member directory via profile fields.’ is closed to new replies.
Skip to toolbar