onacadrianro Posted July 25, 2017 Share Posted July 25, 2017 Admin panel -> International -> Translations -> Type of translation: Theme translations Error message is attached. This was reproduced on multiple terminals. To solve this, i changed the following files (this is a quick fix only): - vendor\symfony\symfony\src\Symfony\Component\Finder\Finder.php public function in($dirs) { $resolvedDirs = array(); $mode = 0777; foreach ((array) $dirs as $dir) { if (is_dir($dir)) { $resolvedDirs[] = $dir; } elseif ($glob = glob($dir, (defined('GLOB_BRACE') ? GLOB_BRACE : 0) | GLOB_ONLYDIR)) { $resolvedDirs = array_merge($resolvedDirs, $glob); } elseif (mkdir($dir, $mode, true) ) { $resolvedDirs[] = $dir; } else { throw new \InvalidArgumentException(sprintf('The "%s" directory does not exist.', $dir)); } } $this->dirs = array_merge($this->dirs, $resolvedDirs); return $this; } - src\PrestaShopBundle\Translation\Provider\TranslationFinderTrait.php public function getCatalogueFromPaths($paths, $locale, $pattern = null) { $messageCatalogue = new MessageCatalogue($locale); $xliffFileLoader = new XliffFileLoader(); $finder = new Finder(); if (null !== $pattern) { $finder->name($pattern); } $translationFiles = $finder->files()->notName('index.php')->in($paths); // if (count($translationFiles) === 0) { // throw new \Exception('There is no translation file available.'); // } foreach ($translationFiles as $file) { if (strpos($file->getBasename('.xlf'), $locale) !== false) { $domain = $file->getBasename('.xlf'); } else { $domain = $file->getBasename('.xlf').'.'.$locale; } $fileCatalogue = $xliffFileLoader->load($file->getPathname(), $locale, $domain); $messageCatalogue->addCatalogue($fileCatalogue); } return $messageCatalogue; } Link to comment Share on other sites More sharing options...
Senga Posted August 23, 2017 Share Posted August 23, 2017 Thanks, you saved my day ! The problem still exists in PS 1.7.2... Link to comment Share on other sites More sharing options...
Karakko Posted October 6, 2017 Share Posted October 6, 2017 Unfortunately this doesn't work on 1.7.2.2. The fields don't show up, it only shows the number of expressions Link to comment Share on other sites More sharing options...
JubJub Posted October 18, 2017 Share Posted October 18, 2017 Actually, this has never been a fix, not even a temporary one. Simply not displaying error messages is not a fix. Systems throw exceptions for good reasons. Link to comment Share on other sites More sharing options...
Medea Web Agency Posted November 6, 2017 Share Posted November 6, 2017 Still got this error in 1.7.2.4.... Please is there any way to fix it? Link to comment Share on other sites More sharing options...
Anão de Jardim Posted March 9, 2018 Share Posted March 9, 2018 Solved... Go /app/Resources/translations/xx-XX/ (xx-XX your language) Extract the ZIP arquive in the same folder (2x) The folder of your language should look like the folder "default" Link to comment Share on other sites More sharing options...
Fijala Posted June 22, 2018 Share Posted June 22, 2018 I know this topic has been covered a year ago, but I'd like to ask exactly where to extract which files? I tried everything, but my template still can not be translated. What does 2x mean? I would be very happy if someone could help me. Many Thanks! Link to comment Share on other sites More sharing options...
edmon Posted June 23, 2018 Share Posted June 23, 2018 I have the same error. I do not find the zip file inside de directory /app/Resources/translations/xx-XX/ (xx-XX your language) . Could anyone help us? thanks!! Link to comment Share on other sites More sharing options...
Fijala Posted June 30, 2018 Share Posted June 30, 2018 Hello everybody,I have now solved it by activating the default template and deleting the template with the translation problem.Then I uploaded the template with the translation problem again and activated and I was able to do the translations again and everything worked out.I hope that will help you.best regards Link to comment Share on other sites More sharing options...
edmon Posted July 3, 2018 Share Posted July 3, 2018 On 30/6/2018 at 5:25 PM, Fijala said: Hello everybody,I have now solved it by activating the default template and deleting the template with the translation problem.Then I uploaded the template with the translation problem again and activated and I was able to do the translations again and everything worked out.I hope that will help you.best regards My problem is with the default template, classic on 1.7... :S Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now