ID:               24611
 User updated by:  itamarc at rogers dot com
 Reported By:      itamarc at rogers dot com
-Status:           Feedback
+Status:           Open
 Bug Type:         *Directory/Filesystem functions
 Operating System: Windows XP
 PHP Version:      4.3.1
 New Comment:

function getDirList($pop, $log) {
        $path = "";

        if (false !== ($directory = dir("$pop"))) {
                $dir = $directory->path;
                print "$dir";
                chdir($dir);
                while (false !== ($entry = $directory->read())) {
                        $path = "$entry";
                        if (!is_file($dir."/".$entry) && !is_link($path) &&
file_exists($path)) {
                                if ($entry !== "." && $entry !== "..") {
                                        if ($dir == $log) {
                                                print "<option 
value='/$entry'>/$entry</option>\n";
                                                getDirList($entry, $log);
                                        } else {
                                                print "<option 
value='/$dir/$entry'>/$dir/$entry</option>\n";
                                                getDirList($entry, $log);
                                        }
                                }
                                $j++;
                        } else {
                                print "<option value='$dir/$entry'>file: 
$dir/$entry</option>\n";
                        }
                }
                $directory->close();
        }
}


Previous Comments:
------------------------------------------------------------------------

[2003-07-13 22:09:32] [EMAIL PROTECTED]

And you should update to PHP 4.3.2 first too..


------------------------------------------------------------------------

[2003-07-13 22:08:53] [EMAIL PROTECTED]

Without seeing the sources it's impossible to start even guessing what
you're doing wrong. Seems like user error to me.

And DO NOT send me any emails. Add the short but complete example
script, max. 20 lines, which clearly shows the problem at hand.


------------------------------------------------------------------------

[2003-07-11 14:37:33] itamarc at rogers dot com

Description:
------------
some directories don't show as such.  even when using chdir() and
looking at all notes on the subject.

I have had and reprocudes this problem for months.  so please don't
just say it's crap.

Reproduce code:
---------------
goto http://zabber.portredirect.com/
login as php
password is net
goto 'Members Options'
goto 'User Files'
goto 'Manage Folders'

I used the site to make 3 folders.

Click on "Make New Directory"

See what it says in the file list.

source code used is available to anyone who E-mails me at:
[EMAIL PROTECTED]

Expected result:
----------------
should who first folder and subfolder as such.
but second folder and any uploaded files show wrong.



------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=24611&edit=1

Reply via email to