I want to display first 100 characters from a rich text field.
I tried this:
{% set sumtext = entry.bodyContent.type('text').first().text|hacksaw(chars='100', append='...') %}
But if there was a new paragraph in the first 100 characters and no full stop - both paragraphs are just joined together without a space.
I then tried:
{% set sumtext = entry.bodyContent.type('text').first().text|hacksaw(allow='<p>', chars='100', append='...') %}
But the
gets displayed on the screen instead of the new line.
what is my best method to display the first 100 characters from a rich text field?