A simple php captcha script
This is one of the easiest CAPTCHA scripts you will ever use. While it doesn’t obscure the text, it will serve its purpose well for many people who need a low-level CAPTCHA solution. This script requires little-to-no setup. The only dependency is the PHP GD library.
Example CAPTCHA image:
http://abeautifulsite.net/blog/wp-co...01/captcha.png
It can be as simple as this to use, but it is also configurable:
<?php
session_start();
include("captcha.php");
$_SESSION['captcha'] = captcha();
echo '<img src="' . $_SESSION['captcha']['image_src'] . '" alt="CAPTCHA" />';
?>
Features:
- Use one or more PNG backgrounds
- Use one or more TTF or OTF fonts
- Set minimum/maximum code lengths (or optionally set the code itself)
- Configure which characters to use
- Set minimum/maximum font size
- Adjustable angle, font color, and shadow
- Includes the free font “Times New Yorker” (for demo purposes) and a sample background image (default.png)
Detail and download https://github.com/claviska/simple-php-captcha