Code:
<actinic:block php="true" > $sShort = ""; $nCount = 0; $sOriginal = '<actinic:variable encoding="perl" name="ProductDescription" selectable="false" />'; foreach(explode(" ", $sOriginal) as $sWord) { if ($nCount > 10) { $sShort .= "..."; break; } $sShort .= $sWord . " "; $nCount++; } echo $sShort; </actinic:block>
Comment