PHP code example of jambtc / yii2-oauth-amazon

1. Go to this page and download the library: Download jambtc/yii2-oauth-amazon 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/ */

    

jambtc / yii2-oauth-amazon example snippets


use jambtc\oauthamazon\amazon;
$checkAmazonUrl = Url::to(['amazon/check-authorization']);

$clientId = Yii::$app->params['amazon.clientId'];
$clientSecret = Yii::$app->params['amazon.clientSecret'];

$lwa = new amazon($clientId, $clientSecret);

echo $lwa->setAmazonScript();
echo $lwa->loginButton($checkAmazonUrl);



php composer.phar