PHP code example of alikhalili / simple-captcha
1. Go to this page and download the library: Download alikhalili/simple-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/ */
alikhalili / simple-captcha example snippets
$captcha->config();
$image = $capthca->getImage();
//in the view
echo "<img src='$image' />";
//or in ajax response to a refresh request:
echo $image;