PHP code example of primipilus / guid
1. Go to this page and download the library: Download primipilus/guid 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/ */
primipilus / guid example snippets
$guid = new \primipilus\guid\Guid();
$guid->generate();
echo $guid;
$guid = new \primipilus\guid\Guid();
// methods of guid:
$guid->generate();
$guid->isValid();
$guid->isZero();
$guid->getValue();
echo $guid;
$guid = \primipilus\guid\GuidHelper::createGeneratedGuid();
$guid = \primipilus\guid\GuidHelper::createGuid('80d58e0c-2524-cb83-208f-954807f1537b');
$guid = \primipilus\guid\GuidHelper::createZeroGuid();
\primipilus\guid\GuidHelper::validate('80d58e0c-2524-cb83-208f-954807f1537b');
\primipilus\guid\GuidHelper::zero('00000000-0000-0000-0000-000000000000');
\primipilus\guid\GuidHelper::generateValue();