Continue reading Restrict search by author from the search query

Restrict search by author from the search query

You can set Relevanssi to index the post author, which will then let you find posts by searching for the name of the author. But what if you want a stricter filter? Where searching for an author would only show posts by that one author, and nothing else? That’s possible too. Add this function to…

Read more Restrict search by author from the search query 0 Comment on Restrict search by author from the search query
Continue reading Target specific part of the post

Target specific part of the post

Relevanssi Premium 2.4.4 introduced a new feature where you can target specific parts of the post straight from the search terms. The format for this is {target:search_term} Target can be one of the following: title: Post title. content: Post content. author: Author display name. comment: Comment text. link: Link from another post. excerpt: Post excerpt.…

Read more Target specific part of the post 0 Comment on Target specific part of the post
Continue reading Indexing image captions for the posts

Indexing image captions for the posts

The use case is I run several newspapers, and the “caption” field when uploading media is where the journalists put the photographer credit. We need to be able to index the photographer bylines, but ideally would want to return the story/commentary where their image was used, not the image itself. If you want to index…

Read more Indexing image captions for the posts 0 Comment on Indexing image captions for the posts
Continue reading Yoast SEO compatibility

Yoast SEO compatibility

Starting from versions 2.4.0 (Premium) and 4.3.0 (Free), Relevanssi doesn’t index posts that have been marked “noindex” in the Yoast SEO settings (“Allow search engines to show this Post in search results?”). If the “noindex” setting is in the default value or set to explicit “yes”, Relevanssi indexes the post. If you want Relevanssi to…

Read more Yoast SEO compatibility 4 Comments on Yoast SEO compatibility
Continue reading Searching Bible verses

Searching Bible verses

A common problem with Relevanssi is Bible verses. All that meaningful punctuation and single digits make exact matching of Bible verses really difficult for Relevanssi, and when searching for Bible verses, exact results are what matters – hitting something similar is generally not very helpful. There’s an easy solution, though: use phrases. Wrapping the verse in…

Read more Searching Bible verses 1 Comment on Searching Bible verses
Continue reading Indexing embedded PDFs for the parent post

Indexing embedded PDFs for the parent post

Relevanssi can automatically index PDF content for the parent post, if the PDF (or other attachment) is attached to the parent post in WordPress. However, that’s not always the case. Sometimes the PDF is attached to the page using an embed, and that doesn’t create a connection between the posts in WordPress. Thus, Relevanssi won’t…

Read more Indexing embedded PDFs for the parent post 0 Comment on Indexing embedded PDFs for the parent post
Continue reading Chamber Dashboard Business Directory

Chamber Dashboard Business Directory

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; }add_filter( ‘relevanssi_prevent_default_request’,…

Read more Chamber Dashboard Business Directory 0 Comment on Chamber Dashboard Business Directory