Da_Elf wrote:it seems my php.ini file says 32MB. why would it max out at 32mb when the original file isnt even 1mb
You'd have to look at the innards of the GD library to get an answer to that.
Your file might seem small, but most image files use compression.... it needs to be decompressed before it can be manipulated (e.g. for thumbnailing)
Somebody might actually
know the answer, I can only
surmise: but I'd suspect that it's taking your original image and converting it to a bitmap internally. Then, if your original image was 320x200 pixels, it would require 256k or memory (4 bytes/pixel) just to hold it in memory. Resizing would require two copies, so 512k. That's just for a small image. 640x480 would take 2.4M.
As I said previously: for whatever reason, any GD image manipulation is know to take large volumes of memory, so you need to make allowance for this when configuring your server to work with large images.
Your alternative, if you don't want to increase PHP memory, is to use external image libraries and call them using exec.