hi all i have this script and it works, i want to change it slightly so that it counts how many words and if its more that 50 then it writes "...more" if its not then dont write anything.
<?
while ($line = mysql_fetch_array($sql_result, MYSQL_ASSOC)) {
$content = $line["news"];
$content=substr($content,0,50);
$content=substr($content,0,strrpos($content," "));
?>
<span class="bodybluebold"><? print $line["date"]; ?></span><br>
<span class="body"><? echo "$content"; ?>"write ..more here"<br>
<br>
<?
}
/ Free resultset /
mysql_free_result($sql_result);
?>
cheers aron.