FEATURE #1831: add recaptcha module

This commit is contained in:
Michal Kváček
2017-04-24 00:00:42 +02:00
parent e41c589225
commit 4a5c9ab1e6
7 changed files with 207 additions and 101 deletions
+1
View File
@@ -19,3 +19,4 @@
!sitemap.php
!image.php
!view.php
!recaptcha.php
+2
View File
@@ -172,6 +172,7 @@ return [
App\Providers\RouteServiceProvider::class,
App\Providers\BladeExtender::class,
\App\Providers\TemplateServiceProvider::class,
\Greggilbert\Recaptcha\RecaptchaServiceProvider::class,
],
/*
@@ -221,6 +222,7 @@ return [
'Validator' => Illuminate\Support\Facades\Validator::class,
'LaravelLocalization' => Mcamara\LaravelLocalization\Facades\LaravelLocalization::class,
'View' => Illuminate\Support\Facades\View::class,
'Recaptcha' => Greggilbert\Recaptcha\Facades\Recaptcha::class,
'Shortcode' => Webwizo\Shortcodes\Facades\Shortcode::class,
],
+66
View File
@@ -0,0 +1,66 @@
<?php
return [
/*
|--------------------------------------------------------------------------
| API Keys
|--------------------------------------------------------------------------
|
| Set the public and private API keys as provided by reCAPTCHA.
|
| In version 2 of reCAPTCHA, public_key is the Site key,
| and private_key is the Secret key.
|
*/
'public_key' => env('RECAPTCHA_PUBLIC_KEY', ''),
'private_key' => env('RECAPTCHA_PRIVATE_KEY', ''),
/*
|--------------------------------------------------------------------------
| Template
|--------------------------------------------------------------------------
|
| Set a template to use if you don't want to use the standard one.
|
*/
'template' => '',
/*
|--------------------------------------------------------------------------
| Driver
|--------------------------------------------------------------------------
|
| Determine how to call out to get response; values are 'curl' or 'native'.
| Only applies to v2.
|
*/
'driver' => 'curl',
/*
|--------------------------------------------------------------------------
| Options
|--------------------------------------------------------------------------
|
| Various options for the driver
|
*/
'options' => [
'curl_timeout' => 1,
'curl_verify' => true,
],
/*
|--------------------------------------------------------------------------
| Version
|--------------------------------------------------------------------------
|
| Set which version of ReCaptcha to use.
|
*/
'version' => 2,
];