Make it with your sql query, it will be faster:
SELECT ..., IF(LENGTH(text)>50, CONCAT(SUBSTRING(text,0,50),'...'), text) as text


[EMAIL PROTECTED] wrote:
Hi there,

Hope you can help me with the following:

I have a query and i'm showing the output:

echo $row->text;

That goes o.k. but the text is 400 characters long and I only one to show the first 50 characters and at the end showing ... dot's..

Help!

Thank you very much!

Frank




--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Reply via email to