trg_lazurus wrote in php 😡aggravated

Not Enough Memory?

I am attempting to write a script that will take an image (jpg) and
resize it on the server side and then save the resized version while
discarding the original.  I have it working, but only with smaller
files.  Once I try to upload a 400K file, the default 8Meg memory
allocation tells me that there is not enough memory.  Of course, if I
increase the memory in php.ini to 20 or so, it works, but this can't be
a good idea.

I find it hard to believe that the system is using all 8 meg for simply
resizing a 400KB file.  I'm not very PHP savvy, so, any help will be useful.