#39918 [Csd->Bgs]: imagecreatefromjpeg doesn't work
| From: | tony2001@php.net | Date: | Thu, 21 Dec 2006 10:09:02 +0000 |
| Subject: | #39918 [Csd->Bgs]: imagecreatefromjpeg doesn't work | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-106720@lists.php.net to get a copy of this message | ||
ID: 39918
Updated by: tony2001@php.net
Reported By: hnthanhphong at yahoo dot com
-Status: Closed
+Status: Bogus
Bug Type: GD related
Operating System: Linux
PHP Version: 5.2.0
Previous Comments:
------------------------------------------------------------------------
[2006-12-21 09:49:15] hnthanhphong at yahoo dot com
I re-saved in Photoshop, and post again it works property.
Thank you very much.
------------------------------------------------------------------------
[2006-12-21 09:43:53] derick@php.net
Photoshop also "repairs" broken JPEGs, PHP does not do that, and will
never do that. I bet if you re-save it in Photoshop PHP can read it as
well.
------------------------------------------------------------------------
[2006-12-21 09:26:22] hnthanhphong at yahoo dot com
But I open this file in photoshop. It works no problem.
------------------------------------------------------------------------
[2006-12-21 09:23:56] derick@php.net
The messages already says it:
Warning: imagecreatefromjpeg() [function.imagecreatefromjpeg]:
'C:\ModelMayhem\Source/userphotos/8_48_R.JPG' is not a valid JPEG file
------------------------------------------------------------------------
[2006-12-21 02:34:33] hnthanhphong at yahoo dot com
Description:
------------
I use PHP 5.2 and GD version bundled (2.0.28 compatible). When I use
function imagecreatefromjpeg to create a thumbnail but it doesn't work
with only one jpeg file. I don't know why?
You can get this jpeg file from http://www.vietmy.com.vn/tmp/test.jpg
Actual result:
--------------
Warning: imagecreatefromjpeg() [function.imagecreatefromjpeg]: gd-jpeg,
libjpeg: recoverable error: Corrupt JPEG data: 321 extraneous bytes
before marker 0xd9 in C:\Source\lib\lib.php on line 129
Warning: imagecreatefromjpeg() [function.imagecreatefromjpeg]:
'C:\ModelMayhem\Source/userphotos/8_48_R.JPG' is not a valid JPEG file
in C:\Source\lib\lib.php on line 129
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=39918&edit=1