|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2014-01-20 10:27 UTC] staviq at gmail dot com
[2014-01-20 10:36 UTC] staviq at gmail dot com
[2016-02-04 16:53 UTC] cmb@php.net
-Status: Open
+Status: Feedback
-Assigned To:
+Assigned To: cmb
[2016-02-04 16:53 UTC] cmb@php.net
[2016-02-14 04:22 UTC] php-bugs at lists dot php dot net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sun Nov 02 08:00:02 2025 UTC |
Description: ------------ All EXIF related function randomly out of nowhere return: Warning: exif_thumbnail(***FILENAME***): File too small (0) in ***SCRIPTNAME*** on line XXX Sometimes function like "exif_thumbnail", or "exif_read_data" will give me expected result, like a tumbnail or array of properties, but most of the time ( about 90% ) it will give me mentioned error. Tried on php 5.5.6 ( XAMPP bundled ) and 5.5.8 ( downloaded from php.net, used with nginx ) Test script: --------------- <? $i = "***FILENAME***"; $image = exif_thumbnail($i, $width, $height, $type); if( max( $width, $height ) == $width ) { $w = 256; $h = 256*( $height/$width ); } else { $h = 256; $w = 256*( $height/$width ); } echo "<img style=\"width: ".$w."px; height: ".$h."px;\" src='data:image/jpeg;base64,".base64_encode($image)."'>"; ?> Expected result: ---------------- Consistent result, either error every time, or expected thumbnail every time. Actual result: -------------- Warning: exif_thumbnail(P1030005.JPG): File too small (0) in E:\xampp\htdocs\t3.php on line 3 Warning: Division by zero in E:\xampp\htdocs\t3.php on line 7