Hi,

    You could try this:

     $script_name = getenv("PATH_TRANSLATED");
     $dir_name = dirname($script_name);
     $d = dir($dir_name);
     $i = 0;
     while ($file = $d->read())

            $file_array[i]  = $file ;
     }

HTH
Sorin Ifrim


----- Original Message -----
From: Brandon Orther <[EMAIL PROTECTED]>
To: PHP User Group <[EMAIL PROTECTED]>
Sent: Saturday, February 17, 2001 5:03 AM
Subject: [PHP] Dir? Can I get a dir listing of the current dir my php file
is in?


> Hello,
>
> I am looking for a way to get a dir listing of the current dir my
phpscript
> is in and putting it into an array.  Does anyone have a quick way to do
> this?
>
> Thank you,
>
> --------------------------------------------
> Brandon Orther
> WebIntellects Design/Development Manager
> [EMAIL PROTECTED]
> 800-994-6364
> www.webintellects.com
> --------------------------------------------
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: [EMAIL PROTECTED]
>


-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to