extends abstract class Phalcon\Validation\Validator
implements Phalcon\Validation\ValidatorInterface
Source on GitHub
Checks if a value is identical to other
use Phalcon\Validation\Validator\Identical;
$validator->add('terms', new Identical([
'accepted' => 'yes',
'message' => 'Terms and conditions must be accepted'
]));
$validator->add(['terms', 'anotherTerms'], new Identical([
'accepted' => [
'terms' => 'yes',
'anotherTerms' => 'yes'