Example : count_sentences
<?php
$smarty->assign('articleTitle','Two Soviet Ships Collide - One Dies. Enraged Cow Injures Farmer with Axe.'
);
?>
Where template is:$smarty->assign('articleTitle','Two Soviet Ships Collide - One Dies. Enraged Cow Injures Farmer with Axe.'
);
?>
{$articleTitle}
{$articleTitle|count_sentences}
Will output:{$articleTitle|count_sentences}
Two Soviet Ships Collide - One Dies. Enraged Cow Injures Farmer with Axe.
2
2
No comments:
Post a Comment