cfn/math-captcha

A simple mathematical operation verification code library, written based on GD library.

v1.0.1 2023-06-15 05:48 UTC

This package is auto-updated.

Last update: 2025-06-15 10:41:19 UTC


README

一个简单的学术运算验证码库,基于GD库编写。

依赖

PHP >= 5.6
GD库扩展

安装

$ composer require cfn/math-captcha

示例

<?php

use MathCaptcha\Captcha;

$ca = new Captcha();
$code = $ca->setDigits(1)->setPoint(100)->setLine(2)->setFontSize(24)->result();
print_r("验证码结果:" . $code . "\n");
$image = $ca->base64();
print_r($image);

作者

邮箱:cfn@leapy.cn
微信:SH-CFN

支持🌙

您的支持就是我们最大的动力,本项目接受任何形式的捐赠,您也可以star支持本项目。

License

MIT