PHP code example of elcodedocle / uuid

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

    

elcodedocle / uuid example snippets


use info\synapp\tools\uuid\UUID;

ID::v3(UUID::v4(), 'BlahBlahSomeRandomStringBlergBlorg');
$v5uuid = UUID::v5(UUID::v4(), 'BlahBlahSomeRandomStringBlergBlorg');

//Pseudo-random UUID:
$v4uuid = UUID::v4();

echo 'UUIDv3: '.$v3uuid."\n".'UUIDv4: '.$v4uuid."\n".'UUIDv5: '.$v5uuid."\n";