Skip to main contentSkip to footer

The Chamber Dashboard Business Directory plugin has a business directory search that’s not compatible with Relevanssi. To disable Relevanssi in those searches, add this to your theme functions.php:

add_filter( 'relevanssi_prevent_default_request', 'rlv_allow_chamber_search', 10, 2 );
function rlv_allow_chamber_search( $prevent, $query ) {
    if ( isset( $_GET['searchtext'] ) ) {
        $prevent = false;
    }
    return $prevent;
}

This will make the business directory search work again. However, I would recommend just using Relevanssi to search the business directory as well – that’s possible, and you don’t need to use the Business Directory default search.

Your account

Not logged in. Log in to see your license details.

Search

Popular Resources

Partial matches to just one custom field

…partial matches but only in the custom field ‘sku‘. * * For posts that have partial matches outside the custom field ‘sku‘, * set the weight to to eliminate them from the search results. * * @param object $match The match object with the custom field detail. * @param int……) ) { $match->weight = 0; } } return $match; } This requires Relevanssi Premium, because in the free version the customfield_detail field is not included in the $match object. (It’s possible to replicate the functionality by checking the sku custom field with get_post_meta( $match->doc, ‘sku‘, true ); but that…Is it possible to set (with filters and/or actions/functions) Relevanssi to use whole words keyword matching for post titles and 2 custom fields, and partial keyword matching only for a specific custom field (sku in this case)? Indeed it is! That is, you can’t set different keyword matching methods to…

A New Chapter for Relevanssi
We are very excited to announce that Relevanssi has found a new home with comesio solutions GmbH, a software company…

Related Posts:

Comment Section:

Leave a Reply

Your email address will not be published. Required fields are marked *

Fill out this field
Fill out this field
Please enter a valid email address.
You need to agree with the terms to proceed