Hi
Ive been trying to enable the CAPTCHA images.
I get this message:
"Images cannot be generated, because your PHP installation's GD library has no JPEG support."
My PHP configure:
'./configure' '--with-apxs2=/usr/local/apache2/bin/apxs' '--with-mysql' '--enable-soap' '--with-openssl' '--with-gd' '--with-jpeg-dir=/usr' '--with-ttf' '--with-freetype' '--enable-gd-native-ttf'
My PHP version is 5.2.3
Working on Linux.
Drupal 5.5
downloaded gdlib, jpeglib is available at /usr.
Other ideas?
I've got this thread going on too: http://drupal.org/node/205298#comment-675529 but still no luck.
Thank in advance,
Rocky
Comments
Comment #1
soxofaan CreditAttribution: soxofaan commentedcould you execute the following php on your server, for example by creating a new page with the "PHP code" input format:
and post the result?
(from http://drupal.org/node/183608#comment-614940)
Comment #2
rockyrackoon CreditAttribution: rockyrackoon commentedsure - here's the result:
what now?
Comment #3
soxofaan CreditAttribution: soxofaan commentedYou have no jpeg support. I'm not very familiar with compiling PHP, so I can't help you with this.
But you seem to have PNG support.
If you are not afraid of hacking, you could change image_captcha to work with PNG instead of JPEG.
at first sight, the only changes in "image_captcha.module" you should do are:
replace "imagejpeg" with "imagepng" (globally in the source code)
and replace 'drupal_set_header("Content-type: image/jpeg");' with 'drupal_set_header("Content-type: image/png");' (around line 400)
try this and report your findings (and post a patch)
I have no time right now to do it myself
Comment #4
rockyrackoon CreditAttribution: rockyrackoon commentedGood job!
I've hacked it to use png and it works now.
Thanks!
what do you mean by "post a patch"?
and where can i find fonts to use with the captcha, cince it keeps warning me about the default font?
thank you anyway
rocky
Comment #5
soxofaan CreditAttribution: soxofaan commentedIf you're not familiar with this, it will probably be easier to do it myself than explaining this, so nevermind ;)
If you're still interested: http://drupal.org/patch
Also note that you now have a custom version of the image CAPTCHA module, so any future upgrade of the module will overwrite your changes.
There are thousands of font sites out there.
I use http://www.dafont.com often
Comment #6
malbrecht CreditAttribution: malbrecht commentedif you follow the hints on your forum thread you might even get jpeg working. It's difficult to keep two seperate pleas for help under control
Comment #7
(not verified) CreditAttribution: commentedAutomatically closed -- issue fixed for two weeks with no activity.