cbValidation
Search…
v3.x
Introduction
Intro
Release History
About This Book
Overview
Installation
Configuration
Declaring Constraints
Available Constraints
Validating Constraints
Validating With Failures
Validating with shared constraints
Validating with a-la-carte constraints
Validating Custom Fields
Validating With Profiles
Displaying Errors
WireBox Integration
Advanced
Custom Validators
Unique ORM Validator
i18n Integration
Custom Validation Managers
Powered By
GitBook
Validating Custom Fields
You can also tell the validation manager to
ONLY
validate on certain fields and not all the fields declared in the validation constraints.
1
prc
.
results
=
validateModel
(
target
=
user
,
fields
=
"login,password"
);
Copied!
This will only validate the
login
and
password
fields.
Custom Includes/Excludes
You can also use the following arguments:
includeFields
: The fields to include in the validation ONLY
excludeFields
: The fields to exclude in the validation
1
prc
.
results
=
validateModel
(
2
target
=
user
,
3
includeFields
=
"username,password"
,
4
excludeFields
=
"id"
5
);
Copied!
Previous
Validating with a-la-carte constraints
Next
Validating With Profiles
Last modified
2yr ago
Copy link
Edit on GitHub
Contents
Custom Includes/Excludes