Commit e60bc671 authored by Levan Velijanashvili's avatar Levan Velijanashvili

Add more examples for Laravel 5

parent b2f507d6
......@@ -46,19 +46,38 @@ return array(
### Usage
Display reCAPTCHA:
##### Display reCAPTCHA
Insert reCAPTCHA inside your form using one of this examples:
For Laravel 4
```php
<?php echo Form::captcha() ?>
````
For Laravel 4 using Blade syntax
```php
{{ Form::captcha() }}
```
For Laravel 5
```php
<?php echo Form::open() ?>
<?php echo Form::captcha() ?>
// <?php app('captcha')->display(); // for Laravel 5 ?>
<?php echo app('captcha')->display(); ?>
```
For Laravel 5 using Blade syntax
```php
{!! app('captcha')->display(); !!}
```
<?php echo Form::submit() ?>
<?php echo Form::close() ?>
For Laravel 5 with `illuminate/html` package using Blade syntax
```php
{!! Form::captcha() !!}
```
Validate, add `'g-recaptcha-response' => 'required|captcha'` to rules array.
##### Validation
Add `'g-recaptcha-response' => 'required|captcha'` to rules array.
```php
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment