PHP code example of php-junior / mm-exchange-rates

1. Go to this page and download the library: Download php-junior/mm-exchange-rates 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/ */

    

php-junior / mm-exchange-rates example snippets

 php
$exchangeRates = new \PhpJunior\ExchangeRates\ExchangeRates();
$exchangeRates->currencies(); // Currencies

$exchangeRates->exchangeRates(['USD', 'EUR']); //နောက်ဆုံး Exchange Rates
$exchangeRates->exchangeRates(['USD', 'EUR'], '2019-01-08'); //သက်ဆိုင်ရာရက် Exchange Rates

$exchangeRates->exchangeRatesBetweenDateRange(['USD', 'AUD'], '2019-12-29', '2020-01-08');

$exchangeRates->convert(100,['USD', 'EUR']); // ဘယ် Currency မှာ မြန်မာငွေ ဘယ်လောက်ရှိလဲ တွက်ရန်
$exchangeRates->convert(100,['USD', 'EUR'], '2019-01-08');