Revision #107 was created by rackycz on Sep 21, 2019, 6:44:05 AM.
edit
Content
[...]
}
```
Validators vs JavaScript:
- There are 2 types of validators. All of them are used in method **rules**, but as you can see, the validator **setPasswordWhenChanged** is my custom validator and needs a special method. *(I just abused a validator to set the password value, no real validation happens inside)*
- If a validator does not need this special method, it is automatically converted into JavaScript and is used on the web page when you are typing.
- If a validator needs the method, it cannot be converted into JavaScript so the rule is checked only in the moment when user sends the form to the server - after successful JavaScript validation.