PHP code example of lukapeharda / hmrc-exchange-rates
1. Go to this page and download the library: Download lukapeharda/hmrc-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/ */
lukapeharda / hmrc-exchange-rates example snippets
// Initialize the client and provide storage path for file cache.
// If path isn't provided "/tmp" will be used.
$hmrcClient = new LukaPeharda\HmrcExchangeRates\Hmrc('/storage/path');
// First param is a four digit representation of a year (2024). Second one is a
// numeric representation of a month (5) without leading zeros.
// Only first param is
// Initialize the client and provide storage path for file cache.
// If path isn't provided "/tmp" will be used.
$hmrcClient = new LukaPeharda\HmrcExchangeRates\Hmrc('/storage/path');
// First param is currency code in ISO 4217. Second one a four digit
// representation of a year (2024). Third one is a numeric representation of a
// month (5) without leading zeros.
// Only first param is