readdir and mime types
| From: | Graham Cossey | Date: | Tue, 22 Nov 2005 14:23:23 +0000 |
| Subject: | readdir and mime types | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-226269@lists.php.net to get a copy of this message | ||
I'm attempting to read a list of files in a directory using readdir()
but am having problems with mpeg files not seemingly being read.
Cope snippet:
$count = 0;
while (false !== ($file = readdir($open_dir)))
{
if ($file != '.' && $file != '..')
{
if (file_exists("$VID_DIR/$file"))
{
$count++;
$count counts any 'avi' files but not 'mpg' files.
Any suggestions much apreciated.
--
Graham