Skip to content
This repository has been archived by the owner on Jun 10, 2024. It is now read-only.

Commit

Permalink
Merge pull request #15 from andrewgorpenko/master
Browse files Browse the repository at this point in the history
Use .env for sensitive information
  • Loading branch information
biscolab committed Jan 19, 2019
2 parents 7f73149 + c962902 commit 3e0fa4e
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 5 deletions.
12 changes: 9 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,17 @@ php artisan vendor:publish --provider="Biscolab\ReCaptcha\ReCaptchaServiceProvid
## Configuration

### Add your API Keys
Open `config/recaptcha.php` configuration file and set `api_site_key`, `api_secret_key` and `version`:
Open `.env` file and set `RECAPTCHA_SITE_KEY` and `RECAPTCHA_SECRET_KEY`:
```php
RECAPTCHA_SITE_KEY=YOUR_API_SITE_KEY
RECAPTCHA_SECRET_KEY=YOUR_API_SECRET_KEY
```

Open `config/recaptcha.php` configuration file and set `version`:
```php
return [
'api_site_key' => 'YOUR_API_SITE_KEY',
'api_secret_key' => 'YOUR_API_SECRET_KEY',
'api_site_key' => env('RECAPTCHA_SITE_KEY', ''),
'api_secret_key' => env('RECAPTCHA_SECRET_KEY', ''),
'version' => 'v2' // supported: v2|invisible
'skip_ip' => [] // array of IP addresses - String: dotted quad format e.g.: 127.0.0.1
];
Expand Down
4 changes: 2 additions & 2 deletions config/recaptcha.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,15 +19,15 @@
* get site key @ www.google.com/recaptcha/admin
*
*/
'api_site_key' => '',
'api_site_key' => env('RECAPTCHA_SITE_KEY', ''),

/**
*
* The secret key
* get secret key @ www.google.com/recaptcha/admin
*
*/
'api_secret_key' => '',
'api_secret_key' => env('RECAPTCHA_SECRET_KEY', ''),

/**
*
Expand Down

0 comments on commit 3e0fa4e

Please sign in to comment.