i cant upload the image i use print_r to show the the value of the array..
i use this function
function resizeImage($name, $size_w, $size_h, $picture_location, $dest_dir, $ext, $quality)
{
$img_src = ImageCreateFromjpeg ($picture_location);
$true_width = imagesx($img_src);
$true_height = imagesy($img_src);
if (($true_width/$size_w) >= ($true_height/$size_h)) {
$width = $size_w;
$height = ($width/$true_width)$true_height;
}
else {
$height = $size_h;
$width = ($height/$true_height)$true_width;
}
$img_des = ImageCreateTrueColor($width,$height);
imagecopyresized ($img_des, $img_src, 0, 0, 0, 0, $width, $height, $true_width, $true_height);
imagejpeg($img_des, $dest_dir.$name.$ext, $quality);
here's my debug image i just only want to know what is the 2 errors --> [error] => 2
Array
(
[userfile] => Array
(
[name] => lily.jpg
[type] =>
[tmp_name] =>
[error] => 2
[size] => 0
)
)