This forum is no longer open and is for reading/searching only.
Please use our new MachForm Community Forum instead.
MachForm Community Forums » MachForm 2
How to create first captch?
Started 16 years ago by SchaefferMarc | 15 posts |
-
Hi,
if I understood well, the only way is to register at recaptcha (what I did) an I got
a private and a public key...now, what are the next steps to do?Posted 16 years ago # -
Hi,
You have to set those keys on "config.php" file, open the file and search for this code :
/** CAPTCHA settings **/ /** To use reCAPTCHA you must get an API key from http://recaptcha.net/api/getkey **/ define('RECAPTCHA_PUBLIC_KEY',''); define('RECAPTCHA_PRIVATE_KEY','');
Fill the keys to those setting, for example
define('RECAPTCHA_PUBLIC_KEY','abcde');
after that simply checked "Turn On Spam Protection (CAPTCHA) (?)" from machform admin form properties
MachForm Support
Posted 16 years ago # -
Another alternative, if you don't like the hassle to get reCaptcha keys, is to use the internal CAPTCHA.
To use it, edit your config.php file, search for this line:
define('USE_INTERNAL_CAPTCHA',false);
change it to become:
define('USE_INTERNAL_CAPTCHA',true);
MachForm Founder
Posted 16 years ago # -
Now I got the text "Type the letters ypu see in the image below" but no image is shown, just an empty box.
Posted 16 years ago # -
Oh, I forgot to let you know that GD extension for your PHP must be enabled in order to use the internal CAPTCHA. Please confirm with your host regarding this, they might have it disabled.
Meanwhile, you can always use the reCaptcha. It should work without any specific requirement.
MachForm Founder
Posted 16 years ago # -
Sorry, this is my first PHP installation ever...how do I enable this GD extension?
In the php.ini under the section "Dynamic Extensions" I don't have something like GD extension=...Posted 16 years ago # -
you can search this line in php.ini
;extension=php_gd2.dll
by default it have comment, remove ";" (semi colon) and it will become like this :
extension=php_gd2.dll
after that you should restart the web server
MachForm Support
Posted 16 years ago # -
Sorry, but I don't have this line in the php.ini file...
What can I do?
Posted 16 years ago # -
Do run your own server ? it's so if your server run on windows, you can check on your /php/ext or /php/extension directory for php_gd2.dll file. If it's exist you can put these line to your php.ini
extension=php_gd2.dll
if you run on linux, I'm afraid there are some steps you have to do. You can find more from this manual :
MachForm Support
Posted 16 years ago # -
Hi redityo,
it's on my own win2003 server with php 5.2.6, but I got no php_gd2.dll..
Posted 16 years ago # -
Hi,
It seems you installing PHP module with installer package, try to download PHP ZIP package the "php_gd2.dll" module should be in "/ext" folder.
MachForm Support
Posted 16 years ago # -
THANKS !!!
After unzipping the "php_gd2.dll" into the "/ext"-folder and modifying the php.ini by adding under the section "Dynamic Extensions" "extension=php_gd2.dll" it works.
Thank you again for your support.
Posted 16 years ago # -
Just a note, I did everything above but still couldn't see the Captcha letters, only the text box to fill in the letters. I finally learned that I was missing "freetype support" which I had to have my server install. Once they did this, everything worked fine.
Posted 16 years ago # -
zoomer, yes you are right. GD with Freetype support is the requirement for the internal CAPTCHA.
MachForm Founder
Posted 16 years ago # -
Great thread, i got my questions answered just by reading your posts guys. Thanks for the impart knowledge. Cheers!
Posted 16 years ago #
Reply
You must log in to post.