PHP code example of league / openid-connect-claims
1. Go to this page and download the library: Download league/openid-connect-claims 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/ */
league / openid-connect-claims example snippets
$claims = new \League\OpenIdConnectClaims\ClaimsSet();
$claims->setIdentifier(123);
$claims->setFirstName('Alex');
$claims->setLastName('Bilbie');
$claims->setNickname('Alex');
$claims->setUsername('alexbilbie');
$claims->setProfileUrl('http://twitter.com/alexbilbie');
$claims->setPictureUrl('https://s.gravatar.com/avatar/14902eb1dac66b8458ebbb481d80f0a3');
$claims->setWebsite('http://alexbilbie.com');
$claims->setEmail('[email protected]');
$claims->setEmailVerified(true);
$claims->setGender('male');
$claims->setBirthDate('YYYY', 'MM', 'DD');
$claims->setZoneInfo('Europe/London');
$claims->setLocale('en_GB');
$claims->setPhoneNumber('0303 123 7300');
$claims->setPhoneNumberVerified(true);
$claims->setAddressStreet('Buckingham Palace');
$claims->setAddressRegion('London');
$claims->setAddressPostalCode('SW1A 1AA');
$claims->setAddressCountry('United Kingdom');