0

I would like to search the specific keyword in all fields of all channels in Expression Engine. As there is only one excerpt option for each channel, I couldn't apply it to all fields in channel. Any option available to make all channel fields marked as excerpt to search entire site?

0
2

The field you choose per-channel to use as an excerpt only determines what will be used to generate the contents of the {excerpt} variable inside the {exp:search:search_results} tag. It has no effect on whether a field is actually searched by the module.

All fields from all channels can be included in search by setting the Is field searchable? option to Yes on that field's Edit Field screen.

Also make sure that you set the search_in parameter on the {exp:search:simple_form} tag to either everywhere or entries, as it defaults to only searching titles.

2
  • @Derek: I dont want to mention channel field names in search result page. Is there any way to put unique field(searching field) name instead of putting {excerpt}? Aug 13 '15 at 8:59
  • Do you mean that you want to display only the specific channel field in which the keywords were found? This cannot be done with the Search module. Aug 13 '15 at 14:45
0

... You can make all fields searchable. Not just excerpts. If you go to your field group, and edit any particular field, you can just set this setting:

enter image description here

LOL, but set that settings to Yes and save the field group. TADA!

0
0

You can use most custom fields in search results:

{exp:search:search_results switch="resultRowOne|resultRowTwo"}
{custom_field_one}
{my_custom_field}
{/exp:search:search_results} 

Bear in mind that if you are searching channels with different field groups you'll need to account for any custom field you want to show in the results.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.