1. Go to this page and download the library: Download vulcanphp/captcha library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
vulcanphp / captcha example snippets
use VulcanPhp\Captcha;
t Form
echo Captcha::render('contact');
// Validate Captcha for contact form
if(Captcha::validate('contact')){
// passed captcha validation
}else{
// failed captcha validation
}
use VulcanPhp\Captcha;
anumeric
echo Captcha::render(
'contact',
Captcha::TYPE_ALPHANUMERIC,
Captcha::DIFFICULTY_HARD, // list of all difficulties:
// Captcha::DIFFICULTY_EASY (Only Small Letters)
// Captcha::DIFFICULTY_MEDIUM (Small Letters + Numbers)
// Captcha::DIFFICULTY_HARD (Capital Letters + Small Letters + Numbers)
);
// Render a Captcha Using Mathematical Calculations
echo Captcha::render('contact', Captcha::TYPE_MATHEMATICAL);
// Validate Captcha for contact form
if(Captcha::validate('contact', Captcha::TYPE_MATHEMATICAL)){
// passed captcha validation
}else{
// failed captcha validation
}
...
Loading please wait ...
Before you can download the PHP files, the dependencies should be resolved. This can take some minutes. Please be patient.