Skip to main contentSkip to footer

This update adds just one new feature, but since it involves a database update, it’s a major version. The new feature adds a session ID to the search logs. The main reason for this is to eliminate duplicate log entries from live searches.

Users of Live Ajax Search have noticed their logs filling up with partial words. If someone searches for “search”, it may get logged as “sea”, “sear”, “searc”, and finally “search” because previously, Relevanssi couldn’t tell these searches were all from the same user.

Now, with the session ID, Relevanssi can tell these are from the same user and can delete the shorter searches, leaving only the final search term in the log. The session ID is based on the user ID for logged-in users and the HTTP user agent for the other users, combined with a 10-minute time window (so the same user will get a new session ID every ten minutes).

If you find this feature interesting, please let me know what you think of it. It’s something of a work-in-progress, so I’m interested in hearing your thoughts and any suggestions for improvement.

2.20 / 4.19

  • New feature: Logging now includes a session ID (based on user ID for logged-in users, HTTP user agent for others, and current time, stable for 10 minutes per user). This removes duplicate searches from live searches, keeping only the final search query.
  • Premium. Minor fix: The pin weights did not appear in the classic editor Relevanssi metabox, despite being stored in the database.

Your account

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

Search

Popular Resources

Related Posts

…(Settings > Relevanssi Premium) and go to the Related tab; check the “Enable related posts” checkbox to enable related posts in the first place. To see related posts on your site, you can check the post types you want in the “Automatically add to these post types” settings to have……Relevanssi automatically append the related posts to your posts. Relevanssi does this using the the_content filter hook, which should place the related posts at the bottom of the posts. The Keyword sources option will determine which content Relevanssi uses to find the related posts. The title is a good default……to use random posts or leave the related posts empty. Adding the related posts manually If you don’t want to append the related posts to the posts automatically, you can use the relevanssi_the_related_posts() function in your templates. The function will print out the related posts. If used without a parameter,…

Total
Total is a popular theme from WPExplorer. It mostly works fine with Relevanssi, with just one little issue. Total sets…
Indexing HTML comments

…which is responsible for removing the comments – so that the comments are not removed. The solution is simple: add this function to your site and rebuild the index. add_filter( ‘relevanssi_remove_punctuation’, ‘rlv_keep_comments’, 9 ); function rlv_keep_comments( $string ) { $string = str_replace( ‘<!’, ”, $string ); return $string; } This……return $string; } This function attaches itself to the punctuation removal filter hook relevanssi_remove_punctuation and since it has priority 9, it runs before the default punctuation removal which runs on priority 10. This function then simply removes the HTML comment start <!, which causes Relevanssi to not remove the comments….By default, Relevanssi does not index HTML comments inside your posts. Relevanssi removes all HTML tags before indexing, and HTML comments (<!– like this –>) are counted as HTML tags. If you have content inside comments that you want to be indexed, you need to modify the punctuation control –…

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