When I look at excerpt results, very often I see two or more words are joined into one. Seems this is because module do strip_tags() on text, and after this text like
<ul><li>One</li><li>Two</li><li>Three</li></ul>
becomes OneTwoThree instead of One Two Three
The problem is in function fuzzysearch_build_excerpt():

  switch ($index->item_type) {
    case 'node':
      node_build_content($entity);
      $text = strip_tags(render($entity->content));
      break;
  }

For solve this issue for me, I have change the string $text = strip_tags(render($entity->content)); to this

      $text = preg_replace('#(<\w.*

)#',' $1',render($entity->content));
$text = strip_tags($text); ?>
This is not so good solution, but works for me.

Comments

awolfey’s picture

Status: Active » Fixed

Thanks Murz. I fixed this in a cruder way, because I don't think we can predict that \w will fit everyone's use cases.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.