5

I'm fine-tuning a search results page and have noticed that "Use this field's values as search keywords" is included both on the matrix field itself, and within each block type / sub-field. I currently have the matrix field checked, but the Form block type / text field unchecked.

When I search my site using the following code:

{% set searchQuery = craft.app.request.getParam('q') %}
{% set entries = craft.entries.search(searchQuery).orderBy('score').limit(20) %}

The content inside the Text field of the Form block shows up in search results. This seems kind of backwards or broken; it's the main content Matrix field for the site, and there are some fields in there that I want to search by, and some that I don't. How do I achieve this?

Additional question; where is this checkbox actually documented? I can't find a description of what "Use this field's values as search keywords" actually does. screenshot of a matrix field

1
  • do you have any further informations to this topic or any feedback from P&T? Nov 4, 2020 at 14:00

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.