0
我想將Magento價格視圖更改爲我的語言。我的意思是我想改變數字。在Magento中應用php函數價格
我有這個PHP函數:
function fanum($englishnumbers)
{
$englishnumbers = str_replace(’0′ , ‘٠’ , $englishnumbers);
$englishnumbers = str_replace(’1′ , ‘١’ , $englishnumbers);
$englishnumbers = str_replace(’2′ , ‘٢’ , $englishnumbers);
$englishnumbers = str_replace(’3′ , ‘٣’ , $englishnumbers);
$englishnumbers = str_replace(’4′ , ‘۴’ , $englishnumbers);
$englishnumbers = str_replace(’5′ , ‘۵’ , $englishnumbers);
$englishnumbers = str_replace(’6′ , ‘۶’ , $englishnumbers);
$englishnumbers = str_replace(’7′ , ‘٧’ , $englishnumbers);
$englishnumbers = str_replace(’8′ , ‘٨’ , $englishnumbers);
$englishnumbers = str_replace(’9′ , ‘٩’ , $englishnumbers);
return $englishnumbers;
}
和:
$echo fanum($en_number);
如何應用這些在Magento價格
謝謝。但我不知道我應該把這些代碼放在哪裏?我應該創建哪些文件? 即時通訊新的magento我會很感激,如果你爲我解釋它 – Moh3n 2015-02-07 16:22:35
你可以把這段代碼放在任何幫助文件中,然後你可以在任何你想要的地方打電話給那個幫手 – 2015-02-07 18:38:18