[wp-trac] [WordPress Trac] #35791: WP_Site_Query class

WordPress Trac noreply at wordpress.org
Mon Jun 13 13:52:41 UTC 2016


#35791: WP_Site_Query class
-------------------------------------------------+-------------------------
 Reporter:  spacedmonkey                         |       Owner:  jeremyfelt
     Type:  task (blessed)                       |      Status:  reviewing
 Priority:  normal                               |   Milestone:  4.6
Component:  Networks and Sites                   |     Version:  4.4
 Severity:  normal                               |  Resolution:
 Keywords:  has-patch needs-testing has-unit-    |     Focuses:  multisite
  tests needs-dev-note                           |
-------------------------------------------------+-------------------------

Comment (by flixos90):

 Replying to [comment:67 jeremyfelt]:
 > [attachment:35791.diff] adds handling for a `search_columns` query var,
 similar to `WP_User_Query`, which allows us to separate searches between
 domain and path when needed. It also adds the wildcard handling (via
 @flixos90) from the patches on #36675.
 >
 > This allows us to better handle searches in `WP_MS_Sites_List_Table`
 when in a subdirectory configuration as all domains will usually be the
 same and should not be searched. A `site_search_columns` filter is added
 for anyone wishing to change the columns on a search.

 It might be useful to add an additional filter
 `site_search_available_columns` to filter the `array( 'domain', 'path' )`
 bit which is used to intersect the array. I would think that most of the
 time you would wanna adjust what's available instead of forcing the query
 var to have a specific value. This could be achived with the existing
 `site_search_columns` filter as well, but with a little overhead.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/35791#comment:68>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list