How to show full post title while searching with any keyword
- priyanka_kethireddyParticipant1 year, 8 months ago #32609
Hello Team,
When I try to search with an keyword the results are showing relevant to the keyword but the full post title was not showing due to that it looks like duplicate results was shown.
How could we show full title of the post?
priyanka_kethireddyParticipant1 year, 8 months ago #32611Please find the screenshot for your reference. Those have different post titles but due to we are showing only highlighting data from method get_highlighting() it was like we are showing repeated data.
wpsolrKeymaster1 year, 8 months ago #32612You can deactivate highlighting with the following code.
use wpsolr\core\classes\WPSOLR_Events; add_filter( WPSOLR_Events::WPSOLR_FILTER_HIGHLIGHTING_FIELDS, function () { /* return [ WpSolrSchema::_FIELD_NAME_TITLE, WpSolrSchema::_FIELD_NAME_CONTENT, WpSolrSchema::_FIELD_NAME_COMMENTS, ]; ] */ // No fields highlighted return []; } , 10, 1 );
priyanka_kethireddyParticipant1 year, 8 months ago #32613Instead of removing the functionality of highlighting, can we increase title characters length. Is that possible?
priyanka_kethireddyParticipant1 year, 8 months ago #32615My bad, it’s not working even I increased the “Maximum size of each snippet text in results” to 1000 from 100. is anything I’m missing?
priyanka_kethireddyParticipant1 year, 8 months ago #32631Sure, Thank you
You must be logged in to reply to this topic.