There are a few areas which can cause Securimage not to work such as not having GD or FreeType installed, incorrect configuration options, or broken session configuration in PHP. Sometimes the problems manifest as a broken captcha image, or code validation failing even when the code is typed correctly. Securimage 3.2 and above tries to make debugging these issues as easy as possible.
To debug issues with Securimage: the first thing to do is to set PHP’s error_reporting and display_errors options so that errors will be visible in the browser window. The 3rd line of securimage.php will set these options for you, but first the line needs to be uncommented. Open securimage.php and find the third line that looks like:
// error_reporting(E_ALL); ini_set('display_errors', 1); // uncomment this line for debugging
To uncomment this line, remove the two // characters from the beginning of the line and save the file. Now all Securimage will cause error messages and warnings to be output to the browser. Now depending on your problem, you should see error messages display.
If the captcha image is not loading, try accessing securimage_show.php directly in your browser. You should see something similar to:
This error message in particular is saying that the SQLite database file is not writeable by the webserver and its permissions need to be changed in order to function properly.
If you are having trouble with playing the audio files, open securimage_play.php directly in your browser and check the output, or if the browser prompts you to save the file, open the resulting WAV file in a text editor to see if any error messages are contained in the output.
If the problem occurs during validation, try to validate your form and see if any error messages are displayed.
Check the FAQ for causes and solutions to common issues if the error message isn’t enough to solve the problem. Once the issues have been resolved, you should comment line 3 of securimage.php again by re-adding the // at the beginning of the line.
If you still can’t solve the problem, you may post a comment or use the contact form to provide as much detail about your problem, and we can attempt to help you resolve the issue.