PHP code example of beycanpress / currency-converter
1. Go to this page and download the library: Download beycanpress/currency-converter 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/ */
beycanpress / currency-converter example snippets
use BeycanPress\CurrencyConverter;
$converter = new CurrencyConverter('CryptoCompare | CoinMarketCap | CoinGecko', 'api key for coinmarketcap');
$paymentPrice = $converter->convert('USD', 'BTC', 15 /* USD Price */);
$paymentPrice // BTC Price