File tree Expand file tree Collapse file tree 1 file changed +4
-20
lines changed
Expand file tree Collapse file tree 1 file changed +4
-20
lines changed Original file line number Diff line number Diff line change 44[ ![ Software License] [ ico-license ]] ( LICENSE.md )
55[ ![ Total Downloads] [ ico-downloads ]] [ link-downloads ]
66
7- Yii2 validator, based on [ https://github.com/elyby/php-tempmailbuster ] ( https://github.com/elyby/php-tempmailbuster )
8- library and [ https://github.com/elyby/anti-tempmail-repo ] ( https://github.com/elyby/anti-tempmail-repo ) reference.
9- Helps to protect you site from users, who use 10-minutes mail services.
7+ Yii2 validator, based on [ daveearley/Email-Validation-Tool] ( https://github.com/daveearley/Email-Validation-Tool )
8+ to protect your site from users, who use 10-minutes mail services.
109
1110## Installation
1211
1312Install the latest version with
1413
1514``` sh
16- $ composer require " ely/yii2-tempmail-validator:~1.0.0 "
15+ $ composer require ely/yii2-tempmail-validator
1716```
1817
1918## Usage
@@ -24,22 +23,7 @@ Once the extension is installed, simply use it in your models:
2423public function rules()
2524{
2625 return [
27- [['email'], \Ely\Yii2\TempmailValidator::className()],
28- ];
29- }
30- ```
31-
32- Also you can configure validator:
33-
34- ``` php
35- public function rules()
36- {
37- return [
38- [['email'], \Ely\Yii2\TempmailValidator::className(),
39- 'message' => '{attribute} is tempmail. You will not pass',
40- 'whiteList' => false,
41- 'secondaryStorage' => ['spam4\.me'],
42- ],
26+ [['email'], \Ely\Yii2\TempmailValidator::class],
4327 ];
4428}
4529```
You can’t perform that action at this time.
0 commit comments