Skip to main contentSkip to footer

Sometimes Relevanssi can get stuck in the indexing. Relevanssi goes past the number of posts in the database and keeps indexing the posts. One possible cause is a too small max_allowed_packet value for your MySQL server.

This value controls how big queries your MySQL server can take. You can see the current value with one of these SQL commands:

SHOW VARIABLES LIKE 'max_allowed_packet';
SELECT @@global.max_allowed_packet;

A reasonable value is at least 4M (4194304). Many servers use 16M (16777216) as the default value. A value of 1M (1048576) is too small for Relevanssi and may cause indexing problems. To adjust the max_allowed_packet value, contact your service provider.

Your account

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

Search

Popular Resources

Blocking pre and code tags

…either. Fortunately it’s easy to completely remove all <pre> and <code> tags and their content both in indexing and excerpt-building. All you need to do is to add the following code to your theme functions.php: add_filter( ‘relevanssi_post_content’, ‘rlv_pre_code’, 10 ); add_filter( ‘relevanssi_excerpt_content]}**’, ‘rlv_pre_code’, 10 ); function rlv_pre_code( $content ) {$content = preg_replace( ‘#<pre.*?</pre>#mis’, ”, $content ); $content = preg_replace( ‘#<code.*?</code>#mis’, ”, $content ); return $content; } This will find all <pre> and <code> tags in posts and replace them and their contents with nothing, both when indexing and when building excerpts. This will immediately take effect for excerpts, and…If your posts have lots of programming code examples in <pre> and <code> tags, those might look pretty bad in the search results. A snippet of programming code isn’t usually a good excerpt, and if you use those tags purely for code snippets, they won’t likely contain significant search content,…

Searching Bible verses
A surprisingly common problem with Relevanssi is Bible verses. All that meaningful punctuation and single digits make exact matching of…

Related Posts:

Currently there are no related posts available.

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