1

admin panel always do translation from en_US. where did i do wrong?

helper

$helper=Mage::helper('test');
$helper->__('Shipping Method');

config.xml

<frontend>
    <translate>
        <modules>
            <test>
                <files>
                    <default>test_test.csv</default>
                </files>
            </test>
        </modules>
    </translate>
</frontend>
<adminhtml>
    <translate>
        <modules>
            <test>
                <files>
                    <default>test_test.csv</default>
                </files>
            </test>
        </modules>
    </translate>
</adminhtml>

app/locale/en_US/test_test.csv

"Shipping address","Shipping Address"
"Billing address","Billing Address"
"Shipping Method","Shipping Method"

app/locale/ar_SA/test_test.csv

"Shipping address","test"
"Billing address","test1"
"Shipping Method","test2"
2

Well, I reckon the tag between <modules> and <files> should be the entire module name with the vendor name, in your case it seems to only be the module name.

So if your module is Test_Test I reckon your config.xml code should be:

<frontend>
    <translate>
        <modules>
            <Test_Test>
                <files>
                    <default>test_test.csv</default>
                </files>
            </Test_Test>
        </modules>
    </translate>
</frontend>
<adminhtml>
    <translate>
        <modules>
            <Test_Test>
                <files>
                    <default>test_test.csv</default>
                </files>
            </Test_Test>
        </modules>
    </translate>
</adminhtml>
1
  • it is working for other place but in helper it is still calling en_US – Qaisar Satti Apr 18 '16 at 9:44

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.