ID: 19997 Updated by: [EMAIL PROTECTED] Reported By: [EMAIL PROTECTED] Status: Bogus Bug Type: Unknown/Other Function Operating System: Linux (Enigma) PHP Version: 4.2.1 New Comment:
Your for loop will obviously not start if $split[0] is 0 since you are using $split[$x] directly as your condition expression. 0 evaluates to false. Use a foreach() loop instead. Previous Comments: ------------------------------------------------------------------------ [2002-10-20 01:34:17] [EMAIL PROTECTED] Sorry, but your problem does not imply a bug in PHP itself. For a list of more appropriate places to ask for help using PHP, please visit http://www.php.net/support.php as this bug system is not the appropriate forum for asking support questions. Thank you for your interest in PHP. Works fine in CVS. ------------------------------------------------------------------------ [2002-10-20 01:00:50] [EMAIL PROTECTED] $split = explode("|", $DaysOfWeek); for ($x = 0; $split[$x]; $x++) { echo $split[$x]."\n"; } //if $DaysOfWeek starts with 0 (eg. 0|1|2) then $split //gets blanked. 1|2|3 or any other combination is fine. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=19997&edit=1
