Recent

better_search_custom_tables_query_where_partsfilterPro only

better_search_custom_tables_query_where_parts

Filter the WHERE parts before generating the final WHERE SQL.

This allows extending the custom tables query by adding additional alternatives that are OR-ed into the where block.

Type: filter
Since: 4.2.4
Source: includes/pro/custom-tables/class-posts-search.php line 516

Parameters

Type Name Description
array $where_parts Array of SQL WHERE fragments that will be OR-ed.
string $search_query Search term.
Posts_Search $instance Current instance of Posts_Search.

Usage

add_filter( 'better_search_custom_tables_query_where_parts', function($where_parts, $search_query, $instance) {
    // ...
    return $where_parts;
} );