01-11-2008, 02:48 AM
|
#7 (permalink)
|
|
La Vida es Sueño
Join Date: Sep 2007
Location: Oldham
Posts: 2,280
Thanks: 90
|
Quote:
Originally Posted by coiyeun2b
Hi @bluesaga. I'm just test:
PHP Code:
//include your function
$str = "Lol! Be nice to Salathe. He's only helping everyone out and that's why we're here.";
echo limitString($str, 50, '...');
//output: Lol! Be nice to Salathe. He's only helping ever
You can see, the word "everyone" had split to "ever" and "yone". I think you can improve function,it get the space near 50 (character) and split at this point. Output return like:
or
|
That would be lovely  I do have some functions in my various projects for this! But maybe you'd care to have a stab at it? Flaunt your stuff!
__________________
The man who comes back through the Door in the Wall will never be quite the same as the man who went out.
|
|
|