Skip to content

Commit 1f97930

Browse files
committed
add readme
1 parent 1d4d22e commit 1f97930

File tree

1 file changed

+12
-11
lines changed

1 file changed

+12
-11
lines changed

README.md

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,13 @@ The preferred way to install this extension is through [composer](http://getcomp
1010
Either run
1111

1212
```
13-
php composer.phar require --prefer-dist baha2odeh/yii2-recaptcha-v3 "*"
13+
php composer.phar require --prefer-dist kekaadrenalin/yii2-module-recaptcha-v3 "*"
1414
```
1515

1616
or add
1717

1818
```
19-
"baha2odeh/yii2-recaptcha-v3": "*"
19+
"kekaadrenalin/yii2-module-recaptcha-v3": "*"
2020
```
2121

2222
to the require section of your `composer.json` file.
@@ -32,10 +32,10 @@ add this to your components main.php
3232
```php
3333
'components' => [
3434
...
35-
'recaptchaV3' => [
36-
'class' => 'Baha2Odeh\RecaptchaV3\RecaptchaV3',
37-
'site_key' => '###',
38-
'secret_key' => '###',
35+
'reCaptcha3' => [
36+
'class' => 'kekaadrenalin\recaptcha3\ReCaptcha',
37+
'site_key' => 'site_key_###',
38+
'secret_key' => 'secret_key_###',
3939
],
4040

4141
```
@@ -45,18 +45,19 @@ and in your model
4545
acceptance_score the minimum score for this request (0.0 - 1.0) or null
4646

4747
```php
48-
public $code;
48+
public $reCaptcha;
4949

50-
public function rules(){
50+
public function rules()
51+
{
5152
return [
5253
...
53-
[['code'],RecaptchaV3Validator::className(),'acceptance_score'=>null]
54+
[['reCaptcha'], \kekaadrenalin\recaptcha3\ReCaptchaValidator::className(), 'acceptance_score' => 0]
5455
];
55-
}
56+
}
5657
```
5758

5859
```php
59-
<?= $form->field($model,'code')->widget(\Baha2Odeh\RecaptchaV3\RecaptchaV3Widget::className());
60+
<?= $form->field($model, 'reCaptcha')->widget(\kekaadrenalin\recaptcha3\ReCaptchaWidget::class) ?>
6061
```
6162

6263

0 commit comments

Comments
 (0)