Download the PHP package pupitooo/bank without Composer
On this page you can find all versions of the php package pupitooo/bank. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Table of contents
Download pupitooo/bank
More information about pupitooo/bank
Files in pupitooo/bank
Download pupitooo/bank
More information about pupitooo/bank
Files in pupitooo/bank
Vendor pupitooo
Package bank
Short Description PHP script works with currencies
License MIT
Homepage https://github.com/pupitooo/bank
Package bank
Short Description PHP script works with currencies
License MIT
Homepage https://github.com/pupitooo/bank
Please rate this library. Is it a good library?
Informations about the package bank
Pupitooo/Bank
Bank is PHP script works with currencies. This extension is for Nette framework 2+.
Requirements
Pupitooo\Bank requires PHP 5.3.2 or higher.
Installation
The best way to install Pupitooo/Bank is using Composer:
Example NEON config
services: - Pto\Bank\Storages\Storage - Nette\Http\SessionSection(@session, 'bank') bank: class: Pto\Bank\Bank setup: - loadCurrency('EUR', NULL, {mask: '1 S', thousand: ' ', point: ',', zeroClear: FALSE, decimal: 2, symbol: € }) - loadCurrency('CZK', NULL, {mask: '1 S', thousand: ' ', point: ',', zeroClear: FALSE, decimal: 2, symbol: Kč}) - loadCurrency('USD')
Example Nette 2.1 use
In Presenter
/** @var \Pto\Bank\Bank @inject */ public $bank; protected function startup() { parent::startup(); $bank = $this->bank; $bank->setDownload(\Pto\Bank\Bank::DOWNLOAD_METHOD_CNB); $bank->loadCurrency("CZK") ->setRate(27.8); $bank->loadCurrency("USD", NULL) ->setProfil(array('mask' => 'S 1', 'thousand' => ',', 'point' => '.', 'zeroClear' => FALSE, 'decimal' => 2, 'symbol' => '$')); $bank->loadCurrency("GBP", NULL, array('mask' => 'S 1', 'thousand' => ',', 'point' => '.', 'zeroClear' => FALSE, 'decimal' => 2, 'symbol' => '£')); } public function actionDefault() { $bank = $this->bank; Nette\Diagnostics\Debugger::barDump($bank->change(1, "EUR", "CZK")); Nette\Diagnostics\Debugger::barDump($bank->change(1, "EUR", "GBP")); Nette\Diagnostics\Debugger::barDump($bank->change(1, "EUR", "HUF")); Nette\Diagnostics\Debugger::barDump($bank->format(1, "EUR")); Nette\Diagnostics\Debugger::barDump($bank->format(1, "EUR", "CZK")); Nette\Diagnostics\Debugger::barDump($bank->format(1, "EUR", "USD")); Nette\Diagnostics\Debugger::barDump($bank->format(1, "EUR", "GBP")); \Nette\Diagnostics\Debugger::barDump($bank->getDefault()); \Nette\Diagnostics\Debugger::barDump($bank->getActualRate("EUR")); \Nette\Diagnostics\Debugger::barDump($bank->getActualRate("CZK")); \Nette\Diagnostics\Debugger::barDump($bank->getActualRate("GBP")); \Nette\Diagnostics\Debugger::barDump($bank->getActualRate("USD")); \Nette\Diagnostics\Debugger::barDump($bank->getActualRate("HUF")); }
In Latte
{1|currency} = {1|currencyTo:"EUR"} {1|currency} = {1|currencyTo:"CZK"} {1|currency} = {1|currencyTo:"USD"} {1|currency} = {1|currencyTo:"GBP"} {1|currency:"CZK"} = {1|currency:"CZK":"EUR"} {1|currency:"USD"} = {1|currency:"USD":"EUR"} {1|currency:"GBP"} = {1|currency:"GBP":"USD"}
Repository http://github.com/pupitooo/bank.
All versions of bank with dependencies
PHP Build Version
Package Version
Requires
php Version
>=5.3.0
nette/nette Version >=2.1
kdyby/curl Version @dev
pupitooo/helpers Version @dev
pupitooo/objects Version @dev
nette/nette Version >=2.1
kdyby/curl Version @dev
pupitooo/helpers Version @dev
pupitooo/objects Version @dev
The package pupitooo/bank contains the following files
Loading the files please wait ....