|
|
|||||||||
|
|||||||||
|
|||||||||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Display Modes |
|
|
|
Free Web 2.0 Code Generator! Generate data entry and reporting .NET Web apps in minutes. Quickly create visually stunning, feature-rich apps that are easy to customize and ready to deploy. Download Now!
|
|
#1
|
|||
|
|||
|
popen vs. opendir/readdir
Hi all!
I wonder if there is any difference when it comes to performance(or anything else..) with these two methods of getting a directory listing: With popen: PHP Code:
With opendir & readdir PHP Code:
Is there a better way of doing this? Please let me know. -Winds- |
|
#2
|
|||
|
|||
|
i do this:
PHP Code:
the ` (tilde) is enterpreted as a system command. Last edited by epyon : June 6th, 2002 at 04:00 PM. |
|
#3
|
|||
|
|||
|
Well opendir is a native PHP function for opening a directory and popen opens a process file pointer with the use of pipes and forking, so my bet you be that opendir is heaps quicker.
|
![]() |
| Viewing: Dev Articles Community Forums > Programming > General Programming Help > popen vs. opendir/readdir |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|