Length Validator
Overview
Defines that length of field value must be in range definied by options.
Attributes
name |
type |
required |
default value |
description |
---|---|---|---|---|
min |
integer |
no |
none |
Minimum value. |
is |
integer |
no |
none |
Exact value. |
max |
integer |
no |
none |
Maximum value. |
message |
string |
no |
none |
Message that will be displayed in case of error. |
Example
<validatesLength min="1" max="3" /> <validatesLength min="5" message="error.login.must.be.at.least.five.letters.long" /> <validatesLength is="8" message="error.password.must.have.eight.letters" />