PHP 4.0 Bug #4996: readdir responding differently Netscape/IE

From: Date: Mon, 12 Jun 2000 23:32:33 +0000
Subject: PHP 4.0 Bug #4996: readdir responding differently Netscape/IE
Groups: php.dev 
Request: Send a blank email to php-dev+get-21162@lists.php.net to get a copy of this message
From: derek@grouptel.net Operating system: Linux PHP version: 4.0 Release Candidate 2 PHP Bug Type: Misbehaving function Bug description: readdir responding differently Netscape/IE The goal is to read a list of files in a directory into an array and sort them. The following code snip returns different results between Netscape and IE. ### snip ############################ $handle=opendir($root.$dir); while ($file = readdir($handle)) { $retVal[count($retVal)] = $file; } closedir($handle); sort($retVal); ### snip ############################ Neither browser gets an error, but in IE the array contains all of the files and directories, in Netscape only the directories are in the array (no files). Env: Linux 2.2.15 Apache 1.3.12 PHP 4.0.0 (MySQL, TrackVars)

« previous php.dev (#21162) next »