Dokładniej to chcę, aby na obrazek 80x80 został naniesiony taki wzorek, lub taki obrazek, jak poniżej (jeden z dwóch):


Proszę o pomoc w wykonaniu takiego skryptu.
<?php function img_resize($img_path,$dest_path,$max_width,$max_height) { $img_width = $img_size[0]; $img_height = $img_size[1]; $new_width = $max_width;# $new_height = $max_height;# $zrd = ImageCreateFromJpeg($img_path); $prz = ImageCreateTrueColor($new_width,$new_height); ImageCopyResized($prz,$zrd,0,0,0,0,$new_width,$new_height,$img_width,$img_height); ImageJpeg($prz, $dest_path, 80); ImageDestroy($zrd); ImageDestroy($prz); #### $background = imagecreatefromjpeg($dest_path); $insert = imagecreatefrompng(\"bg.png\"); imagecolortransparent($insert,imagecolorexact($insert,0,255,30)); $insert_x = imagesx($insert); $insert_y = imagesy($insert); imagecopymerge($background,$insert,0,0,0,0,$insert_x,$insert_y,100); imagejpeg($background,\"\",100); #### } } function img_big($img_path,$dest_path) { $img_width = $img_size[0]; $img_height = $img_size[1]; $new_width = $max_width; $new_height = $max_height; $zrd = ImageCreateFromJpeg($img_path); $prz = ImageCreateTrueColor($img_width,$img_height); ImageCopyResized($prz,$zrd,0,0,0,0,$img_width,$img_height,$img_width,$img_height); ImageJpeg($prz, $dest_path, 80); ImageDestroy($zrd); ImageDestroy($prz); } } ################## $file_path = $_FILES['file']['tmp_name']; $file_name = $_FILES['file']['name']; $file_size = $_FILES['file']['size']; $file_type = $_FILES['file']['type']; $file_error = $_FILES['file']['error']; $error_msg=\" \"; if($file_error>0){ switch($file_error) { case 1: $error_msg.=\"- Za duży plik.<br>\"; case 2: $error_msg.=\"- Za duży plik.<br>\"; case 3: $error_msg.=\"- Plik niedoszedł w całości (spróbuj ponownie).<br>\"; case 4: $error_msg.=\"- Nie wysłałeś żadnego pliku.<br>\"; } }else{ if($file_size>10){ if($file_type==\"image/pjpeg\" || $file_type==\"image/jpeg\"){ $foto_id = '1'; $dest_path = \"./upload/\". $foto_id . \".jpg\"; $resized = img_big($file_path,$dest_path); $dest_path = \"upload/mini/\". $foto_id . \".jpg\"; $resized = img_resize($file_path,$dest_path,80,80); }else{ $error_msg.=\"- Plik niezostał załadowany.<br>\"; } }else{ $error_msg.=\"- Zły typ pliku (tylko JPEGi).<br>\"; } }else{ $error_msg.=\"- Niewysłałeś żadnego pliku.<br>\"; } }else{ $error_msg.=\"- Niewysłałeś żadnego pliku.<br>\"; } } $msg = \"<span class=gold_s>Wystąpiły błędy:</span><br>\" . $error_msg; }else{ $msg = \"Co by niebyło, Fotka dodana.\"; } ?>
<?php $photoImage = ImageCreateFromJPEG(\"http://www.netklinik.com/img_prg/$url_img\"); ImageAlphaBlending($photoImage, true); $logoImage = ImageCreateFromPNG('logo.png'); $logoW = ImageSX($logoImage); $logoH = ImageSY($logoImage); ImageCopy($photoImage, $logoImage, 0, 0, 0, 0, $logoW, $logoH); IMAGEPNG($photoImage); ImageDestroy($photoImage); ImageDestroy($logoImage); ?>
<img src='plik.php?nazwa=obraz.jpg' border='0'>