There's the code lol...and it doesn't matter I forgot the } on the end of the switch.
--------------- Added [DATE]1236625202[/DATE] at [TIME]1236625202[/TIME] ---------------
If anyone was curious about detecting image format this works quite nicely.
PHP Code:
<?php
$filename = 'http://static.php.net/www.php.net/images/php.gif';
$size = getimagesize($filename);
switch ($size['mime']) {
case "image/gif":
echo "Image is a gif";
break;
case "image/jpeg":
echo "Image is a jpeg";
break;
case "image/png":
echo "Image is a png";
break;
}
?>