yunusasuroglu/kimlikno

T.C. Kimlik Numarası doğrulama paketi

dev-main 2024-12-21 20:50 UTC

This package is auto-updated.

Last update: 2025-05-21 21:43:50 UTC


README

Description

This package was developed to facilitate the verification process of the Turkish Republic Identity Number.

Setup

Run the following command to add your package to the project:

composer require yunusasuroglu/kimlikno

Use

You can use the verification functionality provided by the package as follows:

1. Using Laravel

  1. Add your service provider to config/app.php file:
'providers' => [
    yunusasuroglu\KimlikNo\KimlikNoServiceProvider::class,
];
  1. Facade Add:
'aliases' => [
    'KimlikNo' => yunusasuroglu\KimlikNo\Facades\KimlikNo::class,
];
  1. Use:
use yunusasuroglu\KimlikNo\KimlikNo;

$tcNo = "12345678901";

if (KimlikNo::dogrula($tcNo)) {
    echo "Turkish Republic Identity Number is valid.";
} else {
    echo "Turkish Republic Identity Number is not valid.";
}

Requirements

  • PHP 8.0 or above
  • Composer

Contribute

  1. Fork this project.
  2. Create a new feature branch (feature/feature-adi).
  3. Commit your changes (git commit -m 'New feature added').
  4. Push the branch to master (git push origin feature/feature-adi).
  5. Open a Pull Request.

Licence

This project is licensed under the MIT License.