I have managed to save the bindata from a jpeg file into a blob in mysql, however saving the bindata from an imagecreate() call into a blob has totally stumped me!
I've tried this:
ob_start();
imagejpeg($image_thumb);
$image_thumb_string = ob_get_contents();
ob_end_flush();
but when I retreive the picture from the blob is just outputs weird characters.
I know I have the content-type header right and pulling out a blob created from an actual file works fine.
All I need is to know how to get the bindata from a resource indetifer that is returned from imagecreate() and I'll be set!
Thanks