note 26376 added to function.wordwrap
| From: | info*at*cirgo*dot*com at rack1 dot php dot net | Date: | Mon, 28 Oct 2002 22:59:54 +0000 |
| Subject: | note 26376 added to function.wordwrap | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-38671@lists.php.net to get a copy of this message | ||
There was a little bug in the modification of Jeffrey Sambells wordwrap function writen by Alex of
oxyscripts.com...
The modified function would cut off the last character of the first half of the clipped string.
The line that reads:
$str = substr($str,0,$i).$cut.substr($str,$i+1,$str_len-1);
Needs to be:
$str = substr($str,0,$i+1).$cut.substr($str,$i+1,$str_len-1);
At least it does on WIN32 platform.
-Billy Olson
http://www.cirgo.com
--
http://www.php.net/manual/en/function.wordwrap.php
http://master.php.net/manage/user-notes.php?action=edit+26376
http://master.php.net/manage/user-notes.php?action=delete+26376
http://master.php.net/manage/user-notes.php?action=reject+26376