PHP code example of crisu83 / shortid

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

    

crisu83 / shortid example snippets




use Crisu83\ShortId\ShortId;

 $shortid->generate() . "\n";
echo $shortid->generate() . "\n";
echo $shortid->generate() . "\n";
echo $shortid->generate() . "\n";
echo $shortid->generate() . "\n";
echo $shortid->generate() . "\n";
echo $shortid->generate() . "\n";
echo $shortid->generate() . "\n";
echo $shortid->generate();

php composer.phar 

$ php examples/examples.php
mGRdss0
cQEhtSm
WAOsF0B
Wxo-6hC
njJM-67
ySojqwP
yz03QdC
baDvRWZ