PHP code example of zarulizham / laravel-ecommerce-payment

1. Go to this page and download the library: Download zarulizham/laravel-ecommerce-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/ */

    

zarulizham / laravel-ecommerce-payment example snippets


return [
    'password' => env('ECOMMERCE_PASSWORD'),
    'merchant_account_no' => env('ECOMMERCE_MERCHANT_ACCOUNT_NO'),
    'payment_window_url' => env('ECOMMERCE_PAYMENT_WINDOW_URL'),
    'direct_path' => env('ECOMMERCE_DIRECT_PATH'),
    'direct_url' => env('ECOMMERCE_DIRECT_URL'),
    'callback_path' => env('ECOMMERCE_CALLBACK_PATH'),
    'callback_url' => env('ECOMMERCE_CALLBACK_URL'),
    'transaction_type' => env('ECOMMERCE_TRANSACTION_TYPE', 2),
    'response_type' => env('ECOMMERCE_RESPONSE_TYPE', 'HTTP'),
];
bash
php artisan vendor:publish --tag="ecommerce-payment-migrations"
php artisan migrate
bash
php artisan vendor:publish --tag="ecommerce-payment-config"
bash
php artisan vendor:publish --tag="ecommerce-payment-controller"
bash
php artisan vendor:publish --tag="ecommerce-payment-views"