Functions Crashing Script



Okay...so on my website, where people can upload pictures, there is a fairly
major problem with the upload script. Specificaly the part of this script
that automatically generates thumbnails. For some reason, when someone
uploads a picture that is very large in dimensions, in the process of making
a thumbnail, the script crashes, and the browser gives an 'internal server
error' message. Here is the snippet of code that I've narrowed down as the
problem:
$width = $size[0]; //width of original image
$height = $size[1]; //height of original image

$width = round(($width/4)); //width for thumnail
$height = round(($height/4)); //height for thumbnail
$dst_img = ImageCreateTrueColor($width,$height); //creates new image
ImageCopyResized($dst_img, $src_img, 0,0,0,0, $width, $height, $size[0],
$size[1]); //creates thumbnail from original

ImageJpeg($dst_img, "users/$uname/$album/small/$pic_name", 60); //copies
thumnail to appropriate folder with quality adjustment

Now the funny thing is that this works fine on my own computer where I test
stuff out before making it live. When I upload it to my website however,
these large pictures crash. This makes me wonder if it's not some sort of
PHP config setting. The dimension in which I have found this is a problem
is, 2032x1524 pixels. Anyways, any help would be greatly appeciated, and
TIA.
--
<=============>
--Lee
http://www.inaneasylum.org

Goodbye, adios, bis bald, see ya later, wiedersehen, and everything in
between


.



Relevant Pages

  • Re: New Web Site
    ... As a website designer, ... Black backgrounds are very cool, but be sure that any font you use ... Pictures need to be at a high enough resoluytion that you don't ... If you want to make it a clickable link, then use a JAVA script (or ...
    (rec.music.makers.guitar.acoustic)
  • Coppermine Photo Gallery remote compromise
    ... "Coppermine Photo Gallery is a picture gallery script. ... send e-cards and view statistics about the pictures. ... The problem was found in Coppermine 1.0 RC3, ... The upload script ...
    (Bugtraq)
  • [VulnWatch] Coppermine Photo Gallery remote compromise
    ... "Coppermine Photo Gallery is a picture gallery script. ... send e-cards and view statistics about the pictures. ... The problem was found in Coppermine 1.0 RC3, ... The upload script ...
    (VulnWatch)
  • [VulnWatch] Coppermine Photo Gallery remote compromise
    ... "Coppermine Photo Gallery is a picture gallery script. ... send e-cards and view statistics about the pictures. ... The problem was found in Coppermine 1.0 RC3, ... The upload script ...
    (Full-Disclosure)
  • [Full-Disclosure] Coppermine Photo Gallery remote compromise
    ... "Coppermine Photo Gallery is a picture gallery script. ... send e-cards and view statistics about the pictures. ... The problem was found in Coppermine 1.0 RC3, ... The upload script ...
    (Full-Disclosure)