CakePHP-ElasticSearchIndex icon indicating copy to clipboard operation
CakePHP-ElasticSearchIndex copied to clipboard

Way to return results with highlight searched terms

Open blakeloverain opened this issue 10 years ago • 1 comments
trafficstars

The old CakePHP ElasticSearch plugin (https://github.com/kvz/cakephp-elasticsearch-plugin) had a way to highlight search terms with the results. Is there a way to feasibly do this with this plugin/behavior? Can the highlight parameter (http://www.elastic.co/guide/en/elasticsearch/guide/master/highlighting-intro.html) be passed to ElasticSearch from the model?

blakeloverain avatar May 07 '15 17:05 blakeloverain

At a bare minimum, it would be helpful to open up _esSearchRawResults() via a public method, so more than just the association keys can be dealt with. Perhaps the right approach is to develop a wrapper plugin that inherits from the ElasticSearch plugin?

blakeloverain avatar May 07 '15 17:05 blakeloverain