Fix: decimal support for italian language
This commit is contained in:
parent
dad1e55637
commit
742b775f37
@ -2101,6 +2101,7 @@ function price2num($amount,$rounding='',$alreadysqlnb=-1)
|
|||||||
if ($langs->trans("SeparatorDecimal") != "SeparatorDecimal") $dec=$langs->trans("SeparatorDecimal");
|
if ($langs->trans("SeparatorDecimal") != "SeparatorDecimal") $dec=$langs->trans("SeparatorDecimal");
|
||||||
if ($langs->trans("SeparatorThousand")!= "SeparatorThousand") $thousand=$langs->trans("SeparatorThousand");
|
if ($langs->trans("SeparatorThousand")!= "SeparatorThousand") $thousand=$langs->trans("SeparatorThousand");
|
||||||
|
|
||||||
|
//print 'x'.$dec.$thousand.'-';
|
||||||
if ($alreadysqlnb != 1) // If not a PHP number or unknown, we change format
|
if ($alreadysqlnb != 1) // If not a PHP number or unknown, we change format
|
||||||
{
|
{
|
||||||
if ($thousand != ',' && $thousand != '.') $amount=str_replace(',','.',$amount); // To accept 2 notations for french users
|
if ($thousand != ',' && $thousand != '.') $amount=str_replace(',','.',$amount); // To accept 2 notations for french users
|
||||||
|
|||||||
@ -265,8 +265,11 @@ class Translate {
|
|||||||
//if ($this->charset_inputfile == 'UTF-8') $value=utf8_decode($value);
|
//if ($this->charset_inputfile == 'UTF-8') $value=utf8_decode($value);
|
||||||
if ($this->charset_inputfile == 'ISO-8859-1') $value=utf8_encode($value);
|
if ($this->charset_inputfile == 'ISO-8859-1') $value=utf8_encode($value);
|
||||||
|
|
||||||
//$this->setTransFromTab($key,$value);
|
// We do not load Separator values for alternate files
|
||||||
$this->tab_translate[$key]=$value;
|
if (! $alt || (! eregi('^Separator',$key)))
|
||||||
|
{
|
||||||
|
$this->tab_translate[$key]=$value;
|
||||||
|
}
|
||||||
if ($enablelangcacheinsession) $tabtranslatedomain[$key]=$value; // To save lang in session
|
if ($enablelangcacheinsession) $tabtranslatedomain[$key]=$value; // To save lang in session
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user