I'm creating my own simple image manipulation library.
So far so good. It accepts uploaded image files, base64 encoded strings, and URLs. Well, I haven't tested base64 strings and URLs, because right now I'm stuck on file uploads.
http://ajango.org/.dev/phpImageLibrary/ is where you can see the library in action by submitting an image. Files submitted are not uploaded to the server, but instead are accessed via the '/tmp' folder using realpath().
The trouble that I'm having is that I can't seem to use convertToGIF(), and the other conversion functions at that.
$this->imageResource points to the ORIGINAL PHP GD image that I create using the tmp file and imagecreatefromstring().
If I can create the original image from a string, how come I can't convert the image using imagegif() and recreate the image from the outputted file of it?
You can view the source of the library here.
I tried uploading a PNG to be converted into a GIF.
Can anybody tell me what's going on with this?
Warning: imagecreatefromstring(): Empty string or invalid image in /home/ajangox1/public_html/.dev/phpImageLibrary/lib.php on line 70
Warning: Cannot modify header information - headers already sent by (output started at /home/ajangox1/public_html/.dev/phpImageLibrary/lib.php:70) in /home/ajangox1/public_html/.dev/phpImageLibrary/lib.php on line 84
Warning: imagegif() expects parameter 1 to be resource, boolean given in /home/ajangox1/public_html/.dev/phpImageLibrary/lib.php on line 95