Re: error with Captcha
| From: | Tiron Adrian | Date: | Sat, 17 Mar 2007 18:10:27 +0000 |
| Subject: | Re: error with Captcha | ||
| Groups: | php.pear.general | ||
| Request: | Send a blank email to pear-general+get-26867@lists.php.net to get a copy of this message | ||
$options = array(
'font_size' => 24,
'font_path' => './',
'font_file' => 'COUR.TTF'
);
It's just like in the example at http://pear.php.net/manual/en/package.text.text-captcha.php
----- Original Message ----
From: brian <brian@zijn-digital.com>
To: pear-general@lists.php.net
Sent: Saturday, March 17, 2007 6:51:27 PM
Subject: Re: [PEAR] error with Captcha
Tiron Adrian wrote:
> Hello,
>
> I'm trying the first example from the Captcha pakage(wich tries to
> create a png) and i get the following error: Error initializing
> Image_Text (font missing?!).
>
> This is form from my phpinfo(): ./configure............'
> '--with-freetype-dir=/usr'...........and this:
>
> GD Support enabled GD Version bundled (2.0.28 compatible)
> FreeType Support enabled FreeType Linkage with freetype
> FreeType Version 2.2.1
>
> and the command locate ttf | grep -i COUR.TTF gives me:
> /usr/share/fonts/msttcorefonts/cour.ttf
>
> so perhaps i should recompile php with a different path to
> freetype?But i'm not sure exactly which path.......any ideas?Thanks.
> Is there a freetype extention available with yum?(I'm using FC6) .
>
Maybe a permissions problem? You didn't say spceifically how you passed
the location of the font in the options array.
If you think the path is correct, try copying the font to some place
under document root and pointing to there.
b
--
PEAR General Mailing List (http://pear.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php
____________________________________________________________________________________
Looking for earth-friendly autos?
Browse Top Cars by "Green Rating" at Yahoo! Autos' Green Center.
http://autos.yahoo.com/green_center/