Jump to content

[SOLVED] Different site name for different languages


Recommended Posts

Hello, I have a multilanguage site. The name is "Gianluca - The leather craftsman". I see it on all site page meta title and I would like to have it "translated" for the differents languages.

 

For example:

 

english : "Gianluca - The leather craftsman"

italian : "Gianluca - L'artigiano del cuoio"

french : "Gianluca - L'artisan du cuir"

etc...

 

How can I do it? Thanks, Daniele

Link to comment
Share on other sites

ohh sorry for misunderstanding

unfortunately, at the moment it's not possible to translate shop name :(

 

but i've got an idea to some workaround

follow this guide: remove shop name from title

 

then, instead of code:
 

{assign var=shop_name_to_trim value=" - $shop_name"}
<title>{$meta_title|replace:$shop_name_to_trim:''|escape:'htmlall':'UTF-8'}</title>

use:

{assign var=shop_name_to_trim value=" - $shop_name"}
<title>{l s='MyShopName'}{$meta_title|replace:$shop_name_to_trim:''|escape:'htmlall':'UTF-8'}</title>

after that you will be able to translate "MyShopName" with localization > translations > front office translations tool! 

 

 

:-)

  • Like 2
Link to comment
Share on other sites

  • 6 months later...
  • 4 weeks later...

Hi Vekia,

Your suggestion fixed site name translation only in page titles. However there are a lot of other places where it should be translated. For example - in mail templates.

Is there a way to put some "dog-nail" like change $site_name to $this->l('Site name') somewhere in the code so that it will be changed everywhere?

Edited by stasinus (see edit history)
Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...