<?php $val = 1234567.891234567890000; $lngs = array("de_DE", "de_CH", "fr_CH", "nl_NL", "en_US", "en_GB", "cs_CZ"); $crncs = array("EUR", "CZK", "USD", "GBP", "CHF"); foreach($lngs as $lng) { echo $lng . PHP_EOL; foreach ($crncs as $currency) { $fmt = new NumberFormatter($lng, NumberFormatter::CURRENCY ); $fmt->setAttribute(NumberFormatter::FRACTION_DIGITS, 0); // this will be ignored everywhere except in a direct currency-language match echo $currency . "\t" . $fmt->formatCurrency($val, $currency) . "\t" . $fmt->formatCurrency(-1 * $val, $currency) . PHP_EOL; } }
You have javascript disabled. You will not be able to edit any code.
Value for `_results` contains invalid data `array`