I have this code:
{if $data|@count gt 0}
{section name=field loop=$data}
{$data[field].description|substr:0:120}...
<hr/>
{/section}
{/if}
It shows abc123 abc123 a...
.
How can I get the words not to cut?
Why don't you use the truncate modifier http://www.smarty.net/docsv2/en/language.modifier.truncate
You can set it not to break on a word.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With