I want to check if form is valid or not on client side. How can I do it?
In yii1.x we had option “afterValidate”. But on yii2 I can’t find any option like that. So I am using
// How to check if form is valid?<img src='http://www.yiiframework.com/forum/public/style_emoticons/default/huh.gif' class='bbc_emoticon' alt='???' />
Obviously make sure you’re still validating it on the server side as well.
On top of that there is also AJAX Validation for validation that has to be done server side, but you want to make it act like client side validation.