dolec Posted January 4, 2021 Share Posted January 4, 2021 (edited) After upgrade i have error in front Fatal error: Uncaught PrestaShop\PrestaShop\Core\Localization\Exception\LocalizationException: Unknown locale code: pl-PL and in backend PrestaShop\PrestaShop\Core\Localization\Exception\ LocalizationException in src/Core/Localization/Currency.php (line 185) * @throws LocalizationException */ public function getSymbol($localeCode) { if (!isset($this->symbols[$localeCode])) { throw new LocalizationException('Unknown locale code: ' . $localeCode); } return $this->symbols[$localeCode]; } Currency->getSymbol('pl-PL') How can i solve it manually? Edited January 4, 2021 by dolec (see edit history) Link to comment Share on other sites More sharing options...
PrestaServicePro Posted January 4, 2021 Share Posted January 4, 2021 Hi, Install Poland language pack from the "localization" and clear cache of the shop then check again. Link to comment Share on other sites More sharing options...
leo-valentinienoteca Posted January 21, 2021 Share Posted January 21, 2021 Hi, same problem here!! Oops... looks like an unexpected error occurred Unknown locale code: it-IT [PrestaShop\PrestaShop\Core\Localization\Exception\LocalizationException 0] I can't access the back office, when i try prestashop give me this error.. How can you solve this without accessing BO? PS.: i have already tryed to reinstall and apply the right language pack, this won't solve the problem. Thanks Link to comment Share on other sites More sharing options...
PrestaServicePro Posted January 21, 2021 Share Posted January 21, 2021 PHP version? Link to comment Share on other sites More sharing options...
leo-valentinienoteca Posted January 21, 2021 Share Posted January 21, 2021 i'm running WAMP server in local, just a simulation before doing the real work on my hosting. PHP 7.3.21 and tryed also PHP 7.4.9 Link to comment Share on other sites More sharing options...
musicmaster Posted January 29, 2021 Share Posted January 29, 2021 (edited) This error happens when the currency is in the ps_currency table but not in the ps_currency_lang table - at least not for the specified language. The ps_currency_lang table was added in Prestashop version 1.7.6.0. Problems with it are typically the result of problems while upgrading from an older version. Adding entries into the database for each active language for each active currency is usually quite easy to do. In Prestools the Shop Rescue page contains a function to do this automatically. Edited July 28, 2021 by musicmaster (see edit history) Link to comment Share on other sites More sharing options...
a-d-g Posted February 6, 2021 Share Posted February 6, 2021 You are my Hero, hahahaha Link to comment Share on other sites More sharing options...
Coluccini Posted April 11, 2021 Share Posted April 11, 2021 On 1/29/2021 at 6:01 PM, musicmaster said: This error happens when the currency is in the ps_currency table but not in the ps_currency_lang table - at least not for the specified language. The ps_currency_lang table was added in Prestashop version 1.7.6.0. Problems with it are typically the result of problems while upgrading from an older version. I'm trying to upgrade to latest version (1.7.7.3) from a version previous to 1.7.6.0 and I'm getting this error during the upgrade… I've tried to create the table ps_currency_lang (copied from a clean install) and I'm still getting the error. I don't know what else can I try… do you have an idea on what would be the best way to avoid this issue during an upgrade? Link to comment Share on other sites More sharing options...
musicmaster Posted April 12, 2021 Share Posted April 12, 2021 9 hours ago, Coluccini said: I'm trying to upgrade to latest version (1.7.7.3) from a version previous to 1.7.6.0 and I'm getting this error during the upgrade… I've tried to create the table ps_currency_lang (copied from a clean install) and I'm still getting the error. I don't know what else can I try… do you have an idea on what would be the best way to avoid this issue during an upgrade? Copying the table is not enough. It must have an entry for every currency in every language. Link to comment Share on other sites More sharing options...
Coluccini Posted April 12, 2021 Share Posted April 12, 2021 Thanks for your reply! I've done that and got the same error. I've finally fixed by upgrading to 1.7.6 first vía local files and then to 1.7.7.3 Link to comment Share on other sites More sharing options...
Rizzzle Posted July 26, 2021 Share Posted July 26, 2021 Anyone have a solution to this? Happening to me going from 1.7.4 to 1.7.7 Link to comment Share on other sites More sharing options...
musicmaster Posted July 26, 2021 Share Posted July 26, 2021 32 minutes ago, Rizzzle said: Anyone have a solution to this? Happening to me going from 1.7.4 to 1.7.7 And you didn't bother to read the solution mentioned above? Link to comment Share on other sites More sharing options...
Rizzzle Posted July 26, 2021 Share Posted July 26, 2021 4 minutes ago, musicmaster said: And you didn't bother to read the solution mentioned above? There's no solution above. You've said the reason for the error, but not the solution. Link to comment Share on other sites More sharing options...
musicmaster Posted July 26, 2021 Share Posted July 26, 2021 1 minute ago, Rizzzle said: There's no solution above. You've said the reason for the error, but not the solution. I said that some rows were missing. Sherlock Holmes would have concluded that he should add them. Just a few rows with a few fields. Link to comment Share on other sites More sharing options...
Rizzzle Posted July 26, 2021 Share Posted July 26, 2021 3 minutes ago, musicmaster said: I said that some rows were missing. Sherlock Holmes would have concluded that he should add them. Just a few rows with a few fields. You assume everyone has the same technical ability as you. Not everyone is willing to touch a database without clear cut instructions. When it comes to technical issues being vague isn't helpful. You were unable to help Coluccini and your replies aren't helping me. If you have a solution you should consider writing "This is the solution" with a guide, then people would be thankful to you. FIX FOR PEOPLE THAT HAVE THE SAME ISSUE I was able to fix this issue by rerunning the script http://<shop_domain>/install/upgrade/upgrade.php after manually copying the files across. 1 Link to comment Share on other sites More sharing options...
Coluccini Posted July 27, 2021 Share Posted July 27, 2021 My solution was this: upgrade to 1.7.6 first vía local files and then auto upgrade to the latest version Link to comment Share on other sites More sharing options...
juju33el Posted July 28, 2021 Share Posted July 28, 2021 Hi guys, On 1/29/2021 at 6:01 PM, musicmaster said: This error happens when the currency is in the ps_currency table but not in the ps_currency_lang table - at least not for the specified language. The ps_currency_lang table was added in Prestashop version 1.7.6.0. Problems with it are typically the result of problems while upgrading from an older version. I solve my problem thanks to the message above: go to the ps_lang table and note all the ID of the languages installed in your shop then go to the ps_currency_lang table - and check which id are missing - you can add them by simply copying the line and changing the ID... Hope it helps Link to comment Share on other sites More sharing options...
Daniel Santana Posted November 13, 2021 Share Posted November 13, 2021 On 7/28/2021 at 5:31 AM, juju33el said: Hi guys, I solve my problem thanks to the message above: go to the ps_lang table and note all the ID of the languages installed in your shop then go to the ps_currency_lang table - and check which id are missing - you can add them by simply copying the line and changing the ID... Hope it helps Thank you. 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