Answer the question
In order to leave comments, you need to log in
How to use offline validation in Yii2?
Nowhere does it say how to use offline validation.
Let's say we created a standalone validator:
class SimpleValidator extends Validator {
public function validateAttribute($model, $attribute) {
$this->addError($model, $attribute, "Просто ошибка");
}
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question