PHP code example of krowinski / laravel-tinyid

1. Go to this page and download the library: Download krowinski/laravel-tinyid 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/ */

    

krowinski / laravel-tinyid example snippets


  'TinyID' => LaravelTinyID\Facades\TinyID::class

var_dump(TinyId::encode('48888851145')); // will print 1FN7Ab
var_dump(TinyId::decode('1FN7Ab')); // will print 48888851145
bash
$ php artisan vendor:publish