Mam taki problem -
znalazłem skrypt ktory wrzuca mi zdjecia na serwer - dopisalem sobie kawalek który robi mi opis zdjecia -
z tym że mam problem żeby to połaczyć z klasą która uploaduje zdjecie - może ktoś wie jak to zrobić ?

Oto kod dodanie opisu do zdjecia :
<?php $img = ImageCreateFromJPEG("zdjecie.jpg"); //pobranie rozmiarow $width = imagesx($img); $height = imagesy($img); //zmniejszenie zdjecia $height_mini = $height * 0.85; //utworznie nowego obrazka $img_mini = imagecreatetruecolor($width, $height); //nadanie mu tla $kolor_bialy = imagecolorallocate($img_mini, 255, 255, 255); imagefilledrectangle($img_mini, 0, 0, $width, $height , $kolor_bialy); //wklejenie pomniejszonego na nowy imagecopyresampled($img_mini, $img, 0, 15, 0, 0, $width , $height_mini, $width , $height); //$zolty = ImageColorAllocate($img_mini, 255, 255, 0); //imagettftext($img_mini, 12, 0, 30, 20, 0, "verdana.TTF", "http://webmade.org"); //$czerwony=imagecolorallocate($img_mini, 255, 0, 0); imagestring($img_mini, 2, 2, 2, "Opis zdjecia", $czerwony); imagestring($img_mini, 2, 2, 175, "Fot. Jan Nowak", $czerwony); imagejpeg($img_mini,"test2.jpg",100); ?>
a to kod klasy ( niecaly )

<?php // ---------- IMAGE UPLOAD ---------- // we create an instance of the class, giving as argument the php object // corresponding to the file field from the form // All the uploads are accessible from the php object $_FILES $handle = new Upload($_FILES['my_field']); // then we check if the file has been uploaded properly // in its *temporary* location in the server (often, it is /tmp) if ($handle->uploaded) { $handle->Process('./galeria/temp'); // yes, the file is on the server // below are some example settings which can be used if the uploaded // file is an image. $handle->image_resize = true; $handle->image_ratio_y = true; $handle->image_x = 600; // now, we start the upload 'process'. That is, to copy the uploaded file // from its temporary location to the wanted location // It could be something like $handle->Process('/home/www/my_uploads/'); $handle->Process('./galeria/big'); ?>