From 759bc5e507a6606ab490a4c7a7a862f540ea6bd2 Mon Sep 17 00:00:00 2001 From: Sergej Tihonov Date: Sun, 9 Oct 2022 00:45:39 +0200 Subject: [PATCH 1/3] Changed captcha disable fallback to simple false. --- config/captcha.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/config/captcha.php b/config/captcha.php index 9312656..7569829 100644 --- a/config/captcha.php +++ b/config/captcha.php @@ -1,7 +1,7 @@ env('CAPTCHA_DISABLE', !str_contains(env('APP_ENV', 'local'), 'prod')), + 'disable' => env('CAPTCHA_DISABLE', false), 'characters' => ['2', '3', '4', '6', '7', '8', '9', 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'j', 'm', 'n', 'p', 'q', 'r', 't', 'u', 'x', 'y', 'z', 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'J', 'M', 'N', 'P', 'Q', 'R', 'T', 'U', 'X', 'Y', 'Z'], 'default' => [ 'length' => 9, From cc4c025fc929382232d4bbcccea6c68c60e07cf0 Mon Sep 17 00:00:00 2001 From: Sergej Tihonov Date: Sun, 9 Oct 2022 00:56:11 +0200 Subject: [PATCH 2/3] Mentioned captcha disable feature in documentation. --- README.md | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index c853c66..22922db 100644 --- a/README.md +++ b/README.md @@ -18,6 +18,8 @@ for Laravel 4 [Captcha for Laravel Laravel 4](https://github.com/mewebstudio/cap * [Installation](#installation) * [Usage](#usage) * [Configuration](#configuration) + + [Custom settings:](#custom-settings-) + + [Disable validation:](#disable-validation-) * [Example Usage](#example-usage) + [Session Mode:](#session-mode-) + [Stateless Mode:](#stateless-mode-) @@ -94,8 +96,9 @@ for Laravel 5.1+ ] ``` -## Configuration +## Configuration +### Custom settings: To use your own settings, publish config. ```$ php artisan vendor:publish``` @@ -115,6 +118,13 @@ return [ // ... ]; ``` +### Disable validation: +To disable the captcha validation use `CAPTCHA_DISABLE` environment variable. e.g. **.env** config: + +```php +CAPTCHA_DISABLE=true +``` + ## Example Usage ### Session Mode: From eb4e427f48f152ad689e28a6196f0f25b00b1794 Mon Sep 17 00:00:00 2001 From: Sergej Tihonov Date: Sun, 9 Oct 2022 00:58:47 +0200 Subject: [PATCH 3/3] Fixed brocken documentation links. --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 22922db..e89ff8f 100644 --- a/README.md +++ b/README.md @@ -18,11 +18,11 @@ for Laravel 4 [Captcha for Laravel Laravel 4](https://github.com/mewebstudio/cap * [Installation](#installation) * [Usage](#usage) * [Configuration](#configuration) - + [Custom settings:](#custom-settings-) - + [Disable validation:](#disable-validation-) + + [Custom settings:](#custom-settings) + + [Disable validation:](#disable-validation) * [Example Usage](#example-usage) - + [Session Mode:](#session-mode-) - + [Stateless Mode:](#stateless-mode-) + + [Session Mode:](#session-mode) + + [Stateless Mode:](#stateless-mode) - [Return Image](#return-image) - [Return URL](#return-url) - [Return HTML](#return-html)