note 55520 deleted from function.readdir by cece

From: Date: Sun, 20 Nov 2005 11:05:58 +0000
Subject: note 55520 deleted from function.readdir by cece
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-98851@lists.php.net to get a copy of this message
Note Submitter: andy [at] yourimedia * com ---- I think this is faster to remove "." and "..": <?php $dh = opendir($directory); while (false !== ($file = readdir($dh))) { if(strpos($file,'.')>0){ echo $file; } } ?> unless the filename starts with a "."

« previous php.notes (#98851) next »