-
Trim teaser
Is there a way I can have Isotope/Contao automatically trim the teaser of a product if it is too long?
So:
This teaser is too long and needs to be made shorter.
Would be output as something like:
This teaser is too long...
Alternatively, is there a way to limit the number of characters allowed in the teaser box when editing a product?
Thanks
-
Re: Trim teaser
you can do this easily in the template with some code: substr($this->title, 0, 35); where 35 is your max characters. You could also use the word-split functions to not cut through a word.
-
Re: Trim teaser
Thanks for the quick reply! That works great.