Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Currency Symbol in magento

I have created two Magento Store Views in two Different Languages:

  1. English
  2. Dutch

English (EURO) Currency symbol comes in proper manner like € 20.00 but for Dutch Language view it shows me like 20,00 EUR. I wants to setup by default symbol € for both views since the EURO is the same. How can i achieve it in Magento.

like image 661
Ajay Patel Avatar asked May 28 '13 10:05

Ajay Patel


People also ask

How do I activate multiple currency in Magento 2?

How to set up multi-currency in Magento 2? To set up multi-currency in Magento 2, go to Stores > Settings > Configuration. Choose the needed store view, open the General tab and click Currency Setup. In the Currency Options section, choose your Base Currency, Default Display Currency, and Allowed Currencies.

How do I get the currency symbol in Magento 2?

You can use following code: $objectManager = \Magento\Framework\App\ObjectManager::getInstance(); $currencysymbol = $objectManager->get('Magento\Directory\Model\Currency'); echo $currencysymbol->getCurrencySymbol(); But it's not a standard method. You need to inject Magento\Directory\Model\Currency and then use it.

How do you change the currency symbol?

On the Home tab, click the Dialog Box Launcher next to Number. Tip: You can also press Ctrl+1 to open the Format Cells dialog box. In the Format Cells dialog box, in the Category list, click Currency or Accounting. In the Symbol box, click the currency symbol that you want.

What is Magento 2 base currency?

Magento 2 Base currency is a Magento currency set up as default in the backend and is used in setting product prices in the backend. It only can be set at global/ website scope and applied for all stores/ store views. It means that admins cannot set up base currency for each store view.


2 Answers

You can change your locale setting

here is example for English. For that you have to do Minor changes in your Language File. Following is the Directory Structure of File.

=> root/lib/Zend/Locale/Data/en.xml (For English Language)

=> around line 2611 you can see following code.
 <currencyFormat>
      <pattern>¤#,##0.00;(¤#,##0.00)</pattern>
 </currencyFormat>

=> Now Change above code with Following code.

  <currencyFormat>
       <pattern>#,##0.00 ¤;(#,##0.00 ¤)</pattern>
 </currencyFormat>

you can set it to for Dutch.

like image 141
liyakat Avatar answered Sep 30 '22 14:09

liyakat


You can define currency symbol from admin.

Go to system->manage currency and select symbol.

Here you can define currency symbol.

like image 33
ShriHans Avatar answered Sep 30 '22 14:09

ShriHans