Warning: imagecopyresized(): supplied argument is not a valid Image resource in /home/tomstoys/public_html/resizer.php on line 34?JFIF?
?
?>CREATOR: gd-jpeg v1.0 (using IJG JPEG v62), d
efault quality?C?
Plik który wrzucam to jpg
A to jest kod:
<? $szer = $_POST['szer']; $wys = $_POST['wys']; $file = $_FILES['obraz']; $filesize = $file['size']; $filename = "obrazy/" . $file['name']; "obrazy/" . $_FILES["obraz"]["name"]); $typ = "obrazy/" . $_FILES['obraz']['type']; if ($typ == "image/jpeg") { $source_id = imagecreatefromjpeg("obrazy/" . $_FILES["obraz"]["name"]); } if ($typ == "image/png") { $source_id = imagecreatefrompng("obrazy/" . $_FILES["obraz"]["name"]); } if ($typ == "image/gif") { $source_id = imagecreatefromgif("obrazy/" . $_FILES["obraz"]["name"]); } if ($typ == "image/bmp") { $source_id = imagecreatefromwbmp("obrazy/" . $_FILES["obraz"]["name"]); } $thumb = imagecreatetruecolor($szer, $wys); $target_pic = imagecopyresized($thumb, $source_id, 0, 0, 0, 0, $szer, $wys, $szerokosc, $wysokosc); imagejpeg($thumb); } ?>
Ktoś bystry mógłby coś poradzić
