note 17826 added to function.split
| From: | jack at hh dot peril dot org | Date: | Thu, 27 Dec 2001 11:45:31 +0000 |
| Subject: | note 17826 added to function.split | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-23883@lists.php.net to get a copy of this message | ||
If the delimiter string is the first thing that occurs in your searched string, the first array
element returned will be empty, so
$i=0;
while($array[$i]) {
echo $array[$i];
$i++;
}
would fail on the first iteration. be sure to test on isset($array[$i]).
--
http://www.php.net/manual/en/function.split.php
http://master.php.net/manage/user-notes.php?action=edit+17826
http://master.php.net/manage/user-notes.php?action=delete+17826
http://master.php.net/manage/user-notes.php?action=reject+17826