PHP code example of srph / luhn

1. Go to this page and download the library: Download srph/luhn library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

srph / luhn example snippets



/**
 * SRPH\Luhn\luhn(<string>);
 */
SRPH\Luhn\luhn('79927398712') => true


use function SRPH\Luhn\luhn;

echo luhn('79927398712') // => true
bash
$ git clone https://github.com/srph/luhn.php.git && cd luhn.php
$ composer install