src/Util/Validator.php
protected function validateLength($field, $value, $params)
    {
        $length = $this->stringLength($value);
        // Length between
        if (isset($params[1])) {
            return $length >= $params[0] && $length <= $params[1];
        }

        // Length same
        return ($length !== false) && $length == $params[0];
    }
protected function validateLength($field, $value, $params)
    {
        $length = $this->stringLength($value);
        // Length between
        if (isset($params[1])) {
            return $length >= $params[0] && $length <= $params[1];
        }

        // Length same
        return ($length !== false) && $length == $params[0];
    }
protected function validateLength ( $ field , $ value , $ params ) { $ length = $ this -> stringLength ( $ value ) ; // Length between if ( isset ( $ params [ 1 ] ) ) { return $ length >= $ params [ 0 ] && $ length <= $ params [ 1 ] ; } // Length same return ( $ length !== false ) && $ length == $ params [ 0 ] ; }
Validate the length of a string

@param  string $field
@param  mixed  $value
@param  array  $params

@internal param array $fields
@return bool
Validate the length of a string