Skip to content

Commit f7ecbda

Browse files
author
Igor Chepurnoy
committed
Update README.md
1 parent 27fd09f commit f7ecbda

File tree

1 file changed

+36
-3
lines changed

1 file changed

+36
-3
lines changed

README.md

Lines changed: 36 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,37 @@
1-
yii2-validators
2-
===============
1+
Yii2 validators
2+
===============================================
3+
4+
Installation
5+
------------
6+
7+
The preferred way to install this extension is through [composer](http://getcomposer.org/download/).
8+
9+
Either run
10+
11+
```
12+
php composer.phar require --prefer-dist yii2mod/yii2-validators "*"
13+
```
14+
15+
or add
16+
17+
```
18+
"yii2mod/yii2-validators": "*"
19+
```
20+
21+
to the require section of your `composer.json` file.
22+
23+
Usage
24+
-----
25+
1. ECCValidator
26+
```php
27+
/**
28+
* @return array the validation rules.
29+
*/
30+
public function rules()
31+
{
32+
return [
33+
[['creditCard'], \yii2mod\validators\ECCValidator::className()],
34+
];
35+
}
36+
```
337

4-
* ECCValidator

0 commit comments

Comments
 (0)