pekkis/currency-converter

Currency conversion

v0.1.0 2015-11-13 13:52 UTC

This package is not auto-updated.

Last update: 2024-12-21 20:30:19 UTC


README

A library for converting between currencies

Use case

Didn't find a good library (utilizing money class / reliable math) for currency conversion. Needed one. Made one.

Quickstart

<?php

$converter = new CurrencyConverter(
    new FixerIoRateProvider()
);

$money = new Money(2500, new Currency('EUR'));
$sek = $converter->convert($money, 'SEK');

## There's more

Caching and different providers and such. Read code. Kood kood.

Pull requests are welcome.