note 81734 deleted from function.scandir by nlopess
| From: | nlopess@php.net | Date: | Tue, 11 Mar 2008 18:59:53 +0000 |
| Subject: | note 81734 deleted from function.scandir by nlopess | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-136940@lists.php.net to get a copy of this message | ||
Note Submitter: @nonymous
----
foreach(scandir('.') as $f) {
if ($f[0]=='.') continue;
//Do your dirty work code monkey
}
Actualy if you do that, you could skip files that do start with a dot (like .htaccess for
example)...
File name comparaison with '.' and '..' could seem dirty but for me it does the
job ;-)