problems with several JPEGs in GD2
| From: | Mario Lopez | Date: | Mon, 28 Feb 2005 10:54:14 +0000 |
| Subject: | problems with several JPEGs in GD2 | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-209583@lists.php.net to get a copy of this message | ||
Hi,
PHP 4.3.10, GD2
I've noticed that there is a group of JPEG files
that cannot be operated with GD2 functions.
For example, if you try to imagecreatefromjpeg("my.jpg") it
replies:
Warning: imagecreatefromjpeg(): 'my.jpg' is not a valid JPEG file
in C:\Program Files\Apache Group\Apache2\htdocs\test.php on line 20
(this is not a scripting error, it works with lots of other jpegs)
Meanwhile the same my.jpg file can be shown in web browser by
HTML tag <img src="my.jpg">, can be opened in PhotoShop.. and other
programs..
But GD2 thinks that it is not a valid JPEG..
Any suggestions how to deal with these types of JPEGs in GD2?
Any workaround?
Thanks,
Mario