PHP code example of bigenergy / laravel-freekassa-ru

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

    

bigenergy / laravel-freekassa-ru example snippets


Weishaypt\FreeKassa\FreeKassaServiceProvider::class,

'FreeKassa' => Weishaypt\FreeKassa\Facades\FreeKassa::class,

$amount = 100; // Payment`s amount

$url = FreeKassa::getPayUrl($amount, $order_id);

$redirect = FreeKassa::redirectToPayUrl($amount, $order_id);

$rows = [
    'time' => Carbon::now(),
    'info' => 'Local payment'
];

$url = FreeKassa::getPayUrl($amount, $order_id, $desc, $payment_methood, $rows);

$redirect = FreeKassa::redirectToPayUrl($amount, $order_id, $desc, $payment_methood, $rows);
 bash
php artisan vendor:publish --provider="Weishaypt\FreeKassa\FreeKassaServiceProvider"
 php
FreeKassa::handle(Request $request)
 php
'searchOrder' => null  // FreeKassaController@searchOrder(Request $request)
 php
'paidOrder' => null  // FreeKassaController@paidOrder(Request $request, $order)
 php
 Route::get('/freekassa/result', 'FreeKassaController@handlePayment');