Hi guys,
I've written a script to create thumbnails of my images. Here is my code.
list($width, $height) = getimagesize($filename);
$new_height = 100;
$new_width = ($new_height / $height) * $width;
$image_p = imagecreate($new_width, $new_height);
$image = imagecreatefromjpeg($filename);
imagecopyresampled($image_p, $image, 0, 0, 0, 0, $new_width, $new_height, $width, $height);
imagejpeg($image_p "images/thumbs/1.jpg", 100);
When I look at images/thumbs/1.jpg it's just a blank image. Anyone have any ideas why this would happen and how I can fix it?
Thanks