ID: 24869
Updated by: [EMAIL PROTECTED]
Reported By: spam at jerome-gamez dot de
Status: Bogus
Bug Type: GD related
Operating System: Debian Linux 3
-PHP Version: 4CVS-2003-07-30 (stable)
+PHP Version: 4.3.2
New Comment:
(I tried with the latest CVS, not 4.3.2..)
Previous Comments:
------------------------------------------------------------------------
[2003-07-30 11:03:36] [EMAIL PROTECTED]
Works fine for me, must be something wrong in your end.
Most likely the script errors out or something.
------------------------------------------------------------------------
[2003-07-30 10:56:05] spam at jerome-gamez dot de
I have just forgotten to delete the comments... It does not work in
both versions.
This one does not work, too.
<?php
header("Content-type: image/jpeg");
$im = imagecreate(400,30);
$white = imagecolorallocate($im, 255,255,255);
$black = imagecolorallocate($im, 0,0,0);
// Replace path by your own font path
imagettftext($im, 20, 0, 10, 20, $black,
"/var/www/web1/html/sb-drupal/fonts/slkscr.ttf", "Testing... Omega:
&#937;");
imagejpeg($im);
imagedestroy($im);
?>
Greetings
- J�r�me
------------------------------------------------------------------------
[2003-07-30 09:04:53] [EMAIL PROTECTED]
Remove the commments in front of the header() and imagettftext() lines.
Not bug.
------------------------------------------------------------------------
[2003-07-30 09:04:06] [EMAIL PROTECTED]
If you removed the //'s in front of the 'header()' and '
------------------------------------------------------------------------
[2003-07-30 06:44:40] spam at jerome-gamez dot de
Description:
------------
This script below does not lead to an image with some text on it, but
to a set of chars, as you can see on
http://drupal.smallbrainer.de/font.php
We are using PHP 4.3.2, see our phpinfo:
http://www.smallbrainer.de/phpinfo.php
Reproduce code:
---------------
<?php
// header("Content-type: image/jpeg");
$im = imagecreate(400,30);
$white = imagecolorallocate($im, 255,255,255);
$black = imagecolorallocate($im, 0,0,0);
// Replace path by your own font path
// imagettftext($im, 20, 0, 10, 20, $black,
"/var/www/web1/html/sb-drupal/fonts/slkscr.ttf", "Testing... Omega:
&#937;");
imagejpeg($im);
imagedestroy($im);
?>
Expected result:
----------------
An image with some text on it.
Actual result:
--------------
Result is visible at http://drupal.smallbrainer.de/font.php.
- A set of chars, but not an image
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=24869&edit=1