Skip to content

Latest commit

 

History

History
61 lines (45 loc) · 1.6 KB

File metadata and controls

61 lines (45 loc) · 1.6 KB

Cnpj

  • Cnpj()

Validates the structure and mathematical integrity of Brazilian CNPJ identifiers. Ignores non-digit chars, so use ->digit() if needed.

v::cnpj()->assert('00394460005887');
// Validation passes successfully

v::cnpj()->assert('12ABC34501DE35');
// Validation passes successfully

Templates

Cnpj::TEMPLATE_STANDARD

Mode Template
default {{subject}} must be a CNPJ
inverted {{subject}} must not be a CNPJ

Template placeholders

Placeholder Description
subject The validated input or the custom validator name (if specified).

Categorization

  • Identifications

Changelog

Version Description
3.0.0 Templates changed
0.3.9 Created

See Also