ID: 40912 Updated by: [EMAIL PROTECTED] Reported By: programmer at serbiansite dot com -Status: Open +Status: Bogus Bug Type: GetImageSize related Operating System: Windows + Linux PHP Version: 5.2.1 New Comment:
Thank you for taking the time to write to us, but this is not a bug. Please double-check the documentation available at http://www.php.net/manual/ and the instructions on how to report a bug at http://bugs.php.net/how-to-report.php As long as the file contains a header resembling that of a GIF image getimagesize() function will report it as such. Previous Comments: ------------------------------------------------------------------------ [2007-03-25 01:42:25] programmer at serbiansite dot com Description: ------------ getimagesize returns Array for php files if you add GIF at beginning of the file. Reproduce code: --------------- phpgif.php GIF <?php echo "PHP CODE"; ?> test.php <? $image = "phpgif.php"; $image_size = getimagesize($image); echo"<pre>"; print_r($image_size); echo"</pre>"; ?> Expected result: ---------------- Nothing. Because phpgif.php is not a picture. Actual result: -------------- Array ( [0] => 28735 [1] => 28776 [2] => 1 [3] => width="28735" height="28776" [channels] => 3 [mime] => image/gif ) ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=40912&edit=1