Skip to:

Opened 5 years ago

Closed 5 years ago

#3254 closed defect (bug) (fixed)

Add forum search (and improve search keys as array handling)

Reported by: johnjamesjacoby's profile johnjamesjacoby Owned by: johnjamesjacoby's profile johnjamesjacoby
Milestone: 2.6 Priority: high
Severity: normal Version:
Component: Component - Search Keywords:


Topic & Reply searching is currently supported, but sites with many forums do not have a specific way to search for existing forums.

Let's add support for this.

While we're at it, let's also better handle query arguments that are in the shape of an array rather than a string, as there have been a few notices hitting the Dotorg logs.

Attachments (2)

3254.diff (4.4 KB) - added by johnjamesjacoby 5 years ago.
Screen Shot 2019-04-18 at 2.46.13 PM.png (53.9 KB) - added by johnjamesjacoby 5 years ago.
Searching a forum listing for forums with "gen" in them

Download all attachments as: .zip

Change History (3)

5 years ago

5 years ago

Searching a forum listing for forums with "gen" in them

#1 @johnjamesjacoby
5 years ago

  • Resolution set to fixed
  • Status changed from assigned to closed

In r6903:

Search: add support for fs query-arg to search forums list:

  • Introduces bbp_sanitize_search_request() to encapsulate duplicate code across forums/topics/replies
  • Introduces bbp_get_search_type_ids() to stub out future enhancements (tags, users, etc...)
  • Use these new functions where intended
  • Update bbp_get_search_terms() to loop through known search-type IDs

This commit also fixes debug notices that would happen when these query arguments were not explicitly strings.

Fixes #3254.

Note: See TracTickets for help on using tickets.