I have a frontend search form and I want to search within a matrix block. I have checked the box to make this field searchable.
And I'm using the expanded search plugin.
Here is my results code
{% set query = craft.app.request.getParam('q') %}
{% set expandedResults = craft.expandedSearch.search(query) %}
{% for result in expandedResults %}
<strong data-field="{{result.matchedField}}">{{result.entry.title}}</strong><br>
<p>{{result.matchedValue}}</p>
<a href="{{result.entry.url}}">{{result.entry.url}}</a>
{% else %}
<p>Sorry, no results for {{query}}.</p>
{% endfor %}
Now if I try to search for a specific word from my content, the search result shows only the Entries that have the query word in their title, but not inside content.
php craft resave/entries --update-search-index
. Also, search indexes are updated asynchronously using a queue job, so make sure you have a queue listener active on your development machine so the queue jobs are actually processed.