note 35110 added to features.file-upload

From: Date: Wed, 20 Aug 2003 03:25:51 +0000
Subject: note 35110 added to features.file-upload
Groups: php.notes 
Request: Send a blank email to php-notes+get-54726@lists.php.net to get a copy of this message
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. ---- Manual Page -- http://www.php.net/manual/en/features.file-upload.php Edit Note -- http://master.php.net/manage/user-notes.php?action=edit+35110 Delete Note -- http://master.php.net/manage/user-notes.php?action=delete+35110&report=yes Reject Note -- http://master.php.net/manage/user-notes.php?action=reject+35110&report=yes

« previous php.notes (#54726) next »