jhonoryza/recaptcha-v3
最新稳定版本:1.0.0
Composer 安装命令:
composer require jhonoryza/recaptcha-v3
包简介
google recaptcha v3
README 文档
README
This package just provide backend validation rule for google recaptcha v3
Features
- Lightweight
- Simple & easy to use
- Support Laravel version >= 10
- Recaptcha validation rules
Installation
composer require jhonoryza/recaptcha-v3
publish config file
php artisan vendor:publish --tag=recaptcha-v3-config
Usage
add Recaptcha rule to validation
<?php use Illuminate\Http\Request use Jhonoryza\RecaptchaV3\Recaptcha; public function store(Request $request) { $request()->validate([ 'email' => ['required', 'max:100','email'], 'password' => ['required', 'max:100'], 'captcha_token' => [new Recaptcha], ]) }
update .env file, add you own recaptcha from here
GOOGLE_RECAPTCHA_SITE_KEY= GOOGLE_RECAPTCHA_SECRET_SITE_KEY= GOOGLE_RECAPTCHA_MIN_SCORE=0.5 GOOGLE_RECAPTCHA_URL="https://www.google.com/recaptcha/api/siteverify"
Security
If you've found a bug regarding security please mail jardik.oryza@gmail.com instead of using the issue tracker.
License
The MIT License (MIT). Please see License File for more information.
统计信息
- 总下载量: 8
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2024-06-21