Nochmal....
Ich möchte neue Bilder (PNG) so erstellen, das sie genau so gross sind wie der $Text der eingegeben wird.
... also wenn man "Hallo Welt" eingibt soll das zu erzeugende Bild auch etwa die, dem Text entsprechende Größe haben....
<?
$size="3";
$text = "Test Textlangundhoch";
$imx = imagefontheight($size);
$imy = imagefontwidth($size)*strlen($text);
header ("Content-type: image/png");
$image = imagecreate ($imx, $imy);
$black = ImageColorAllocate ($image, 0, 0, 0);
$white = ImageColorAllocate ($image, 255, 255, 255);
ImageTTFText ($image, $size, 0, 10, 20, $white, "arial.ttf", $text);
imagepng($image);
ImageDestroy ($image);
?>
Die arial.ttf habe ich auch im verzeichnis, aber es klappt nicht...
Aber was mach ich
H I E R falsch?????