![]() |
|
|||
|
merhaba
kullandığım scriptte değişiklik yapmak istiyorum resim gösterilirken içine yazı yazmak istiyorum... <img src="view2.php?picture=<?=$line[picture];?>&i=3" border="0"> resim yukarıdaki url de görüntüleniyor Aşağıdaki örneği üstteki url ye nasıl uyarlayabilirim <?php // Set the content-type header("Content-type: image/png"); // Create the image $im = imagecreatetruecolor(400, 30); // Create some colors $white = imagecolorallocate($im, 255, 255, 255); $grey = imagecolorallocate($im, 128, 128, 128); $black = imagecolorallocate($im, 0, 0, 0); imagefilledrectangle($im, 0, 0, 399, 29, $white); // The text to draw $text = 'merhaba!'; // Replace path by your own font path $font = 'arial.ttf'; // Add some shadow to the text imagettftext($im, 20, 0, 11, 21, $grey, $font, $text); // Add the text imagettftext($im, 20, 0, 10, 20, $black, $font, $text); // Using imagepng() results in clearer text compared with imagejpeg() imagepng($im); imagedestroy($im); ?> sorunu halletmeme yardım edecek kişiye 1 .info domain benden ![]() ufak bir armagan.. teşekkürler |
|
|||
|
merhaba söylediginizi uyguladim ama hata verdi;
Warning: imagecolorallocate(): supplied argument is not a valid Image resource in /home/pro/public_html/mevcut.php on line 171 |
|
|||
|
merhaba kod asagidadir (viev2.php)
<? $resim = "/pictures/".$picture; include "duzenle.php"; $thumb=new thumbnail("$resim"); $size = getimagesize("$resim"); $width= $size[0]; $height= $size[1]; if($i == "1"){ $max_width= "120"; if ($width>$max_width){ $thumb->size_width(120); }else{ $thumb->size_width($width); $thumb->size_height($height); } } if($i == "2"){ $max_width = "400"; if ($width>$max_width){ $thumb->size_width(400); }else{ $thumb->size_width($width); $thumb->size_height($height); } } if($i == "3"){ $max_width = "150"; if ($width>$max_width){ $thumb->size_width(150); }else{ $thumb->size_width($width); $thumb->size_height($height); } } if($i == ""){ $thumb->size_width($width); $thumb->size_height($height); } $thumb->jpeg_quality(70); $thumb->show(); ?> |
|
||||
|
Fonksiyonlarla baska dosyalara bagliymis gerci ama yine de birseyler yapmaya calistim, bilmeden ancak bu kadar. Calismassa kizma
Araya girdigim yere buyuk harflerle aciklama yazdim. Baska bir isimle kaydedip test et. PHP- Kodu:
__________________
peace love union respect |
![]() |
| Seçenekler | |
| Stil | |
|
|
Benzer Konular
|
||||
| Konu | Konuyu Başlatan | Forum | Cevaplar | Son Mesaj |
| Kaynak Kodu ve Resimin Üzerine gelince Kaydetme butonu | BEBEX | HTML XML XHTML DHTML CSS | 7 | 2006-06-17 21:50 |
| video uzerine yazı yazmak | ugurcan | Müzik Sinema TV Kitap | 9 | 2006-04-13 19:10 |
| Resimlere Yazı yazmak | eflatun | Webmaster Genel Konular | 1 | 2006-01-25 13:41 |
| aviye yazı yazmak | yakese | Webmaster Genel Konular | 3 | 2006-01-03 20:53 |
| Updated, kırmızı yazı gitti; siyah yazı gelmiş.. | dedektif | Internetten Para | 9 | 2005-05-28 19:07 |