PHP code example of zeroweb / azuresso
1. Go to this page and download the library: Download zeroweb/azuresso 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/ */
zeroweb / azuresso example snippets
use Symfony\Component\HttpFoundation\Request;
use ZeroWeb\AzureSSO;
$request = Request::createFromGlobals();
## $azureCreds = array of the credenetials
$config = [
'clientId' => 'client id',
'clientSecret' => 'client secret',
'tenantId' => 'tenant id',
'scope' => 'User.Read GroupMember.Read.All',
'returnUrl' => 'https://localhost/sso',
'returnGroups' => true, // set false to not return the user groups. If set to true,