|
|
@@ -494,6 +494,8 @@ EOF';
|
|
|
|
|
|
$kwota = (!substr_count($kwota, '.')) ? $kwota.'.00' : $kwota;
|
|
|
list($zlote, $grosze) = explode('.', $kwota);
|
|
|
+ $zlote = ltrim($zlote, '0');
|
|
|
+ if ($zlote == '') $zlote = '0';
|
|
|
if (strlen($grosze) == 1) $grosze .= "0";
|
|
|
elseif (strlen($grosze) > 2) $grosze = round(substr($grosze, 0, 2).".".substr($grosze, 2), 0);
|
|
|
$zlote = strrev(wordwrap(strrev($zlote), 3, '.', true));
|
|
|
@@ -509,8 +511,9 @@ EOF';
|
|
|
else $odmiana = 1;
|
|
|
if ($setka) $resultArr[] = $setka;
|
|
|
if ($dziesiatka) $resultArr[] = $dziesiatka;
|
|
|
- $resultArr[] = $jednosc;
|
|
|
- $resultArr[] = $tysiace[$tysiac][$odmiana];
|
|
|
+ if ($jednosc == $jednosci[0] && $zlote != '0') $jednosc = '';
|
|
|
+ if ($jednosc) $resultArr[] = $jednosc;
|
|
|
+ if ($setka || $dziesiatka || $jednosc || $tysiac == 0) $resultArr[] = $tysiace[$tysiac][$odmiana];
|
|
|
}
|
|
|
|
|
|
$resultArr[] = $grosze . "/100";
|