Over 1 Meg blank page

See all posts See thread Reply

Re: Over 1 Meg blank page new!
by Jon, 17 years, 3 months ago
Hi Colin, thanks for your reply, appreciated.

Unfortunately i can't change the memory, i use a shared webspace.

After trying for hours, I am not sure it is a file size problem. I reduced one image to 600Kb but left the dimensions to 2272px wide......it gave same problem.

I am trying to upload images and yes using your script to first resize width to:
$handle->image_x         = 1000;

and then creating thumb:
$handle->image_x         = 200;

I echoed a statemement that proved it uploaded to the tmp folder but wouldn't echo this:

if ($handle->processed) {
            echo" everything was fine !";

Is there anything you can think of? or a way around it? Would be very grateful.

Kind regards
JonReply
Re: Over 1 Meg blank page new!
by colin, 17 years, 3 months ago
It is actually a file size issue. It is also a file dimension issue.

The dimensions that you want (2272px wide) are too big for the memory you have available. What happens is that the class (GD actually) converts the image into a bitmap before resizing it, or compressing it. A bitmap will require a lot more room than the JPEG version of the same image.

So if you have a file with a great dimensions (a lot of pixels), and even though the file size is small (in KB), the class will require a lot of memory to process your image.

There is no way around but reduce the dimensions of your picture, or increase the memory limit on your host.Reply
Re: Over 1 Meg blank page new!
by Marcelo, 14 years, 1 month ago
Colin, I'm with that problem, apparentenly, how do I solve (I'm using Apache)?Reply
Re: Over 1 Meg blank page new!
by colin, 14 years, 1 month ago
See the first item on the FAQReply