Validate CPF and CNPJ Numbers: Validate CPF and CNPJ tax pay numbers in Brazil

Recommend this page to a friend!
  Info   View files Documentation   View files View files (7)   DownloadInstall with Composer Download .zip   Reputation   Support forum   Blog    
Last Updated Ratings Unique User Downloads Download Rankings
2021-06-25 (2 months ago) RSS 2.0 feedNot yet rated by the usersTotal: 22 All time: 10,337 This week: 259Up
Version License PHP version Categories
cpfcnpj-validator 1.0MIT/X Consortium ...5PHP 5, Validation
Description Author

This package can validate CPF and CNPJ tax pay numbers in Brazil.

It provides the implementation of rules to validate tax payer numbers of Brazilian citizens and companies.

Application controllers need to pass a HTTP request object to the package so it can take the CPF or CNPJ values to verify if the values are correct.

Picture of Thiago Przyczynski
  Performance   Level  
Name: Thiago Przyczynski <contact>
Classes: 13 packages by
Country: Brazil Brazil
Innovation award
Innovation award
Nominee: 6x

Details

CPF/CNPJ Validator

A Laravel package to work with CNPJ validation.

CPF is an individual taxpayer identification number given to people living in Brazil, both native Brazilians and resident foreigners.

CNPJ is the National Registry of Legal Entities in Brazil.

Installation

` composer install thiagoprz/cpfcnpj-validator`

Usage

<?php

namespace App\Http\Controllers;

use Illuminate\Http\Request;

class CnpjController extends Controller
{
    ...
    /
     * Store action
     */
    public function store(Request $request)
    {
        $this->validate($request, [
            'cnpj' => 'cpfcnpj', // CPF/CNPJ validation
            ...
        ]);
        ...
    }
    ...
}
  Files folder image Files  
File Role Description
Files folder imagesrc (2 files, 1 directory)
Accessible without login Plain text file composer.json Data Auxiliary data
Accessible without login Plain text file README.md Doc. Read me

  Files folder image Files  /  src  
File Role Description
Files folder imagelang (3 directories)
  Plain text file CpfCnpj.php Class Class source
  Plain text file CpfCnpjServiceProvider.php Class Class source

  Files folder image Files  /  src  /  lang  
File Role Description
Files folder imageen (1 file)
Files folder imagept-BR (1 file)
Files folder imagept_BR (1 file)

  Files folder image Files  /  src  /  lang  /  en  
File Role Description
  Accessible without login Plain text file validation.php Aux. Auxiliary script

  Files folder image Files  /  src  /  lang  /  pt-BR  
File Role Description
  Accessible without login Plain text file validation.php Aux. Auxiliary script

  Files folder image Files  /  src  /  lang  /  pt_BR  
File Role Description
  Accessible without login Plain text file validation.php Aux. Auxiliary script

 Version Control Unique User Downloads Download Rankings  
 100%
Total:22
This week:0
All time:10,337
This week:259Up
For more information send a message to info at phpclasses dot org.