Skip to:
Content
Pages
Categories
Search
Top
Bottom

bp_has_members – multiple search terms?

  • Avatar of shanebp
    shanebp
    Moderator

    @shanebp

    I trying to filter online members based on multiple zipcodes (from a radial search).
    Is there a way to use multiple terms in ‘search terms’ ?
    Or is there some other way to accomplish this (which does not work) :

    `
    //$zipcodes = “21345, 33445, 23239″;
    $zipcodes = array(“21345, 33445, 23239″);
    $filter_members = ‘user_id=0&type=online&per_page=999&search_terms=’ . $zipcodes . ‘&populate_extras=0′;

    bp_has_members( $filter_members )
    `

Viewing 2 replies - 1 through 2 (of 2 total)
  • Avatar of shanebp
    shanebp
    Moderator

    @shanebp

    Did the task by getting all the user_ids for $zipcodes and then using them in a string – include=string
    $filter_members = ‘include=’ . $zip_ids . ‘&type=online&per_page=999&populate_extras=0′;

    But would still like to know if it is possible to use multiple terms in ‘search terms’ ?

    Avatar of Quint
    Quint
    Participant

    @qrahaman

    @shanebp,

    Did you get resolution on your question about “search terms”? Do you mind sharing the code that worked for you?

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

You must be logged in to reply to this topic.