eseguo questa funzione:
$maxx = 126;
$maxy = 126;
$source_image_URL = "../fotoutenti/$nickk/foto1.jpeg";
$source_image = imagecreatefromjpeg($source_image_URL);
list($width, $height) = getimagesize($source_image_URL);
$percent1 = $width / $maxx; //6,35
$percent2 = $height / $maxy; // 4,76
$percent = max($percent1,$percent2);
$new_eight = round($height /$percent);
$new_width = round($width /$percent);
$dest_image = imagecreatetruecolor($new_width, $new_eight);
imagecopyresampled ($dest_image, $source_image, 0, 0, 0, 0,
$new_width, $new_eight, $width, $height);
imagejpeg($dest_image);
imagedestroy($dest_image);
imagedestroy($source_image);
come risultato ottengo una serie di caratteri stranissimi al posto della immagine.. come mai?