how to detect type of image
| From: | Alain Roger | Date: | Sat, 21 Apr 2007 10:45:49 +0000 |
| Subject: | how to detect type of image | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-253420@lists.php.net to get a copy of this message | ||
Hi,
In my web application, end user is able to load images (png, jpeg, gif,..)
into database.
I would like to know how can i detect automatically the type of image (pnd,
jpeg,...) ?
i do not want to check the extension because this is easily faked... just by
renaming it.
Does it exist a technique for that ?
thanks a lot,
--
Alain
------------------------------------
Windows XP SP2
PostgreSQL 8.1.4
Apache 2.0.58
PHP 5