note 39871 rejected from function.is-file by tomsommer

From: Date: Fri, 13 Feb 2004 17:30:54 +0000
Subject: note 39871 rejected from function.is-file by tomsommer
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-65106@lists.php.net to get a copy of this message
Note Submitter: annettetruong@yahoo.com ---- The preceding works well except I get an error when I try to access $ext[1] when it doesn't exist (i.e. for each directory). I changed it to simply check for the existence of an extension and it works fine. Annette. $ext=explode('.', $file); if($file != '.' && $file != '..' && array_key_exists(1, $ext)) { echo "$file<br>\n"; }

« previous php.notes (#65106) next »