1. Go to this page and download the library: Download amedev/smart-payment 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/ */
amedev / smart-payment example snippets
return [
'default' => 'zarinpal', // Default payment gateway
'gateways' => [
'zarinpal' => \SmartPayment\Gateways\ZarinpalGateway::class,
// You can register your own gateway classes like:
// 'idpay' => \App\Gateways\CustomIDPayGateway::class,
],
'models' => [
'order' => \App\Models\Order::class, // Your custom Order model
'transaction' => \App\Models\Transaction::class, // Your custom Transaction model
],
];