andrey-klimenko/yii2-paypal

The PayPal extension for the Yii2 framework

Installs: 58

Dependents: 0

Stars: 9

Watchers: 4

Forks: 18

Open Issues: 2

Language: PHP

v0.1.1 2014-05-16 16:43 UTC

README

PayPal payment extension for the Yii2.

Installation

Add to the composer.json file following section:

php composer.phar require --prefer-dist marciocamello/yii2-paypal "*"
"marciocamello/yii2-paypal": "dev-master"

Add to to you Yii2 config file this part with component settings:

'paypal'=> [
    'class'        => 'marciocamello\Paypal',
    'clientId'     => 'you_client_id',
    'clientSecret' => 'you_client_secret',
    'isProduction' => false,
     // This is config file for the PayPal system
     'config'       => [
         'http.ConnectionTimeOut' => 30,
         'http.Retry'             => 1,
         'mode'                   => \marciocamello\Paypal::MODE_SANDBOX, // development (sandbox) or production (live) mode
         'log.LogEnabled'         => YII_DEBUG ? 1 : 0,
         'log.FileName'           => '@runtime/logs/paypal.log',
        'log.LogLevel'           => \marciocamello\Paypal::LOG_LEVEL_FINE,
    ]
],