Creating a PNG with a TrueType font
<?php
Header
("Content-type: image/png");
$im ImageCreate(630,80);
$blue ImageColorAllocate($im,0x5B,0x69,0xA6);
$white ImageColorAllocate($im,255,255,255);
$black ImageColorAllocate($im,0,0,0);
ImageTTFText($im4501057,$black,"CANDY",$_GET['text']);
ImageTTFText($im450654,$white,"CANDY",$_GET['text']);
ImagePNG($im);
?>
<IMG src="txt.php?text=<?php echo urlencode($text)?>">