Forums › Forums › Search & Filter Pro › the_excerpt/custom field data, am I missing something?
Tagged: V3
- This topic has 6 replies, 2 voices, and was last updated 6 years, 2 months ago by Trevor.
-
Anonymous(Private) September 26, 2018 at 3:04 pm #189413
I have a search form that is working and outputting the results as expected, to a degree.
All the data being searched is in various custom fields (ACF) and whilst this is being searched, the results output isn’t showing any data related to that. I would expect the results to show some kind of snippet with the search term.
Is there something I’ve missed?
Trevor(Private) September 26, 2018 at 3:46 pm #189420It depends on which Display Results you are using:
https://searchandfilter.com/documentation/search-results/#display-results-method
Trevor(Private) September 26, 2018 at 4:15 pm #189428The shortcode display results method uses our exemplar template – results.php. The basic steps for customising the file are set here, but you would need to do the coding:
https://searchandfilter.com/documentation/search-results/using-a-shortcode/#customising-the-results
The ACF documentation gives you how to get the data from their fields. This post shows an example results.php template file that gets ACF fields:
Anonymous(Private) September 26, 2018 at 4:28 pm #189435Trevor, I’m sorry but that doesn’t work.
I already have a custom results template.
I know how to output an ACF field easy enough.
The issue here is that the S&F plugin has no option to generate any kind of excerpt/snippet based on the search results of those custom fields.
All the example will do is output the entire custom field value, not the search term/snippet.
Trevor(Private) September 27, 2018 at 3:28 pm #189560Hi Simon. Great to speak with you. I can see you have gone as far as you can in having a customised excerpt based on the search phrase. These ARE options within Relevanssi, and I think we will produce an addon for that plugin for our V3.x series of the Search & Filter plugin, possibly for V3.1.
-
AuthorPosts