Overwriting Translations not working in PHPStorm
Forum rules
Always add your Laravel, Aimeos and PHP version as well as your environment (Linux/Mac/Win)
Spam and unrelated posts will be removed immediately!
Always add your Laravel, Aimeos and PHP version as well as your environment (Linux/Mac/Win)
Spam and unrelated posts will be removed immediately!
Overwriting Translations not working in PHPStorm
Hi everyone,
First I am new to Laravel and PHPstorm so I might be missing something obvious to everyone, but I am not seeing it.
I have Aimeos demo running and wanted to change the translation for Basket to Shopping cart as outlined here: https://aimeos.org/docs/latest/laravel/ ... anslations
In PHPStorm I am editing the shop.php file located in under project -> config -> Shop.php
The code I am using is copied from the documentation and is shown below.
I am working on a Mac M1 (chip if it matters) with a Laravel environment built from Valet. I am running PHP 7.4, MySQL 8 and everything else is the latest.
Is there some cache that needs to be flushed or something? I have restarted NGINX and the valet framework to no success.
Thanks for helping.
First I am new to Laravel and PHPstorm so I might be missing something obvious to everyone, but I am not seeing it.
I have Aimeos demo running and wanted to change the translation for Basket to Shopping cart as outlined here: https://aimeos.org/docs/latest/laravel/ ... anslations
In PHPStorm I am editing the shop.php file located in under project -> config -> Shop.php
The code I am using is copied from the documentation and is shown below.
Code: Select all
'i18n' => [
'en_US' => [
'client' => [
'basket' => ['Shopping cart'],
],
],
],
Is there some cache that needs to be flushed or something? I have restarted NGINX and the valet framework to no success.
Thanks for helping.
Re: Overwriting Translations not working in PHPStorm
Most likely, you don't have "en_US" in the Locale > Locale list of the admin backend and if yes it's not the one that's used by default. After installing Aimeos, "en" language is default and to change the translation for that language use:
Code: Select all
'i18n' => [
'en' => [
'client' => [
'basket' => ['Shopping cart'],
],
],
],
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, give us a star
If you like Aimeos, give us a star
Re: Overwriting Translations not working in PHPStorm
Thank you!
I did as you suggested, but unfortunately I am still seeing no change the the basket text.
After making the change do I need to flush any caches? I even restarted dnsmasq, NGINX and PHP just in case.
The whole demo site is showing in English, so I am thinking the language must be set to English too. I can login to the demo and the demo site runs just fine. Not sure what else I can add here that would be insightful.
Thank you
I did as you suggested, but unfortunately I am still seeing no change the the basket text.
After making the change do I need to flush any caches? I even restarted dnsmasq, NGINX and PHP just in case.
The whole demo site is showing in English, so I am thinking the language must be set to English too. I can login to the demo and the demo site runs just fine. Not sure what else I can add here that would be insightful.
Thank you
Re: Overwriting Translations not working in PHPStorm
You need to clear the content cache using:
Furthermore, change something in the basket so it's refreshed.
Code: Select all
php artisan aimeos:clear
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, give us a star
If you like Aimeos, give us a star
-
- Posts: 3
- Joined: 04 Aug 2021, 21:00
Re: Overwriting Translations not working in PHPStorm
Laravel v8.52.0 (PHP v7.4.22); Aimeos 2021.07.04; Mac OSX 11.4
I am having the same issue (because we're working on the same project.
I have tried:
... added a product to the 'basket', removed the product, and still getting the same results.
I am having the same issue (because we're working on the same project.
I have tried:
Code: Select all
php artisan aimeos:clear
Code: Select all
php artisan cache:clear
Code: Select all
brew services restart redis
Re: Overwriting Translations not working in PHPStorm
The strings are case sensitive. Can you try instead:
This will change the name of the header in the offscreen basket if you click on the basket item.
Code: Select all
'i18n' => [
'en' => [
'client' => [
'Basket' => ['Shopping cart'],
],
],
],
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, give us a star
If you like Aimeos, give us a star
-
- Posts: 3
- Joined: 04 Aug 2021, 21:00
Re: Overwriting Translations not working in PHPStorm
That worked!
And so you're aware, the https://aimeos.org/docs/2021.x/laravel/ ... anslations does not reference case-sensitivty.
And so you're aware, the https://aimeos.org/docs/2021.x/laravel/ ... anslations does not reference case-sensitivty.
Re: Overwriting Translations not working in PHPStorm
We've added a hint about case sensitivity now
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, give us a star
If you like Aimeos, give us a star