Reputation: 11
I am - as a basic magento user - trying to translate to dutch, but it is not working as expected. I've had a clean install in 2.0.
What did I do?
composer.json
{
"name": "magento/language-nl_nl”,
"description": "Dutch (Netherlands) language",
"version": "100.0.2",
"license": [
"OSL-3.0",
"AFL-3.0"
],
"require": {
"magento/framework": "100.0.*"
},
"type": "magento2-language",
"autoload": {
"files": [
"registration.php"
]
}
}
Language.xml
<?xml version="1.0"?>
<!--
/**
* Copyright © 2015 Magento. All rights reserved.
* See COPYING.txt for license details.
*/
-->
<language xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:App/Language/package.xsd">
<code>nl_NL</code>
<vendor>magento</vendor>
<package>nl_nl</package>
</language>
Registration.php
<?php
/**
* Copyright © 2015 Magento. All rights reserved.
* See COPYING.txt for license details.
*/
\Magento\Framework\Component\ComponentRegistrar::register(
\Magento\Framework\Component\ComponentRegistrar::LANGUAGE,
'nl_nl',
__DIR__
);
I've added a nl_NL.csv file "Search entire store here...","Zoek TESTING..."
Cached
And ... Nothing! Anybody willing to hint me a clue this christmas?
Thank in advance!
Upvotes: 0
Views: 2268
Reputation: 1660
I'm unsure what's the right way to translate strings in Magento 2, but I succeeded with the following simple approach for a German translation:
vendor/magento/module-catalog/i18n/en_US.csv
to vendor/magento/module-catalog/i18n/de_DE.csv
de_DE.csv
in a text editor and translated the values in the second columni18n/*.csv
files in other modulesUpvotes: 0
Reputation: 11
Yes, two error in above text:
Now it Works!
Upvotes: 1