Download the PHP package alikdex/yii2-recaptcha without Composer
On this page you can find all versions of the php package alikdex/yii2-recaptcha. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download alikdex/yii2-recaptcha
More information about alikdex/yii2-recaptcha
Files in alikdex/yii2-recaptcha
Package yii2-recaptcha
Short Description reCaptcha without curl
License MIT
Informations about the package yii2-recaptcha
Google reCAPTCHA widget for Yii2
Based on google reCaptcha API 2.0.
Installation
The preferred way to install this extension is through composer.
- Either run
or add
to the require
section of your application's composer.json
file.
-
Configure the component in your configuration file (web.php). The parameters siteKey and secret are optional. But if you leave them out you need to set them in every validation rule and every view where you want to use this widget. If a siteKey or secret is set in an individual view or validation rule that would overrule what is set in the config.
- Add
ReCaptchaValidator
in your model, for example:
or just
Usage
For example:
or
or simply