Skip to content

Commit

Permalink
docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Eugene Terentev committed Apr 7, 2015
1 parent c45e2f1 commit 8c27a48
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
8 changes: 8 additions & 0 deletions README.md
Expand Up @@ -167,3 +167,11 @@ This behavior is designed to save uploaded files in the corresponding relation.
}
```
See additional settings in the corresponding class.

# Validation
There are two ways you can perform validation over uploads.
On the client side validation is performed by Blueimp File Upload.
Here is [documentation](https://github.com/blueimp/jQuery-File-Upload/wiki/Options#validation-options) about available options.

On the server side validation is performed by [[yii\web\UploadAction]], where you can configure validation rules for
[[yii\base\DynamicModel]] that will be used in validation process
1 change: 1 addition & 0 deletions src/actions/UploadAction.php
Expand Up @@ -78,6 +78,7 @@ class UploadAction extends BaseAction

/**
* @var array
* @see https://github.com/yiisoft/yii2/blob/master/docs/guide/input-validation.md#ad-hoc-validation-
*/
public $validationRules;

Expand Down

0 comments on commit 8c27a48

Please sign in to comment.