1. Go to this page and download the library: Download szunisoft/laravel-mnb 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/ */
szunisoft / laravel-mnb example snippets
/*
* Wsdl file location.
* */
'wsdl' => env('MNB_SOAP_WSDL', 'http://www.mnb.hu/arfolyamok.asmx?wsdl'),
'cache' => [
/*
* Desired cache driver for service.
* */
'store' => env('MNB_CACHE_DRIVER', 'file'),
/*
* Minutes the cached currencies will be held for.
* Default: 24hrs (1440)
* */
'minutes' => env('MNB_CACHE_MINUTES', 1440),
]
use SzuniSoft\Mnb\Laravel\Facade\Mnb
$currency = Mnb::currentExchangeRate('EUR');