Hmm... well, you should move the header() line so it's right above the imagepng() line. If the script is outputting any text error messages, the browser might not display them because it's expecting a PNG image. Just for clarity, here's the modified code:
code:
<?php
$im = @imagecreate(100, 50)
or die("Cannot Initialize new GD image stream");
$background_color = imagecolorallocate($im, 255, 255, 255);
$text_color = imagecolorallocate($im, 233, 14, 91);
imagestring($im, 1, 5, 5, "This will soon be replaced with something else.", $text_color);
header("Content-type: image/png");
imagepng($im);
imagedestroy($im);
?>