note 35110 deleted from features.file-upload by vincent
| From: | vincent@php.net | Date: | Thu, 11 Sep 2003 12:34:02 +0000 |
| Subject: | note 35110 deleted from features.file-upload by vincent | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-56117@lists.php.net to get a copy of this message | ||
Note Submitter: doph@onid.orst.edu Oregon State Uni.
----
If you can't get your PHP script to detect image files using getimagesize() or
exif_imagetype(), there is a way to detect image files (or any type of files).
$type_string = $HTTP_POST_FILES["userfile"]["type"]; // or
$_FILES["userfile"];
$type_array = explode("/", $type_string);
$file_type = $type_array[0];
There are more information attached with the file when It is uploaded to the server.