note 38917 deleted from function.is-dir by didou
| From: | didou@php.net | Date: | Mon, 12 Jan 2004 10:37:28 +0000 |
| Subject: | note 38917 deleted from function.is-dir by didou | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-63342@lists.php.net to get a copy of this message | ||
Note Submitter: xlabATadaptiveNOSPAMartsDOTnet
----
I noticed issues when using this function on IIS 5 /PHP 4.3.0. Everything worked fine until I
renamed a directory in Explorer, after which, I started getting errors stating that the directory
didn't exist. Did everything short of remaking the webserver, to no avail. So my workaround
was:
<?
function listDirs($dir){
$files=scanDir($dir); // user-defined function, not PHP 5 function
for($i=0;$i<count($files);$i++){
if($files[$i]=="."||$files[$i]=="..")continue;
// I'll just have to refrain from using periods in directory names
if(!preg_match("/\./",$files[$i]))$dirs[]=$files[$i];
}
return $dirs;
}
?>