Re: We only need to create like 70 threads to push that annoyingly wide thread down
Posted by:
Word Smith
()
Date: December 10, 2012 11:03AM
There should be some code added to truncate any word over 20 characters. Something like:
function myTruncate2($string, $limit, $break=" ", $pad="...")
{
// return with no change if string is shorter than $limit
if(strlen($string) <= $limit) return $string;
$string = substr($string, 0, $limit);
if(false !== ($breakpoint = strrpos($string, $break))) {
$string = substr($string, 0, $breakpoint);
}
return $string . $pad;
}