Jump to content

[Solved] different default language?


Recommended Posts

If I set up 2 different domains, say one .se and one .com
Install prestashop on both of these pointing to the same database.
would it be possible to easy change the default language on the two stores? say, .com has english and .se has swedish for default? i.e override the default language parameter on one of the stores.

any ideas?

Link to comment
Share on other sites

what if I just edit configuration class? would it be possible to do some kind of override on the get command?
like if(input = PS_LANGUAGE_DEFALUT) return language I want?

I did a try on this idea and ended up changing configuration.php in class
if($key=='PS_LANG_DEFAULT')
return 1;

where 1 is the id of the language I want, seems to be working, but I will do some more testing of this and se if it works well.. if it does, maybe prestashop 1.2 should get a new feature? :)
like the possibility to set different languages for different domains as default as this would be great from a SEO point of view (better than having many different languages on one domain)

Link to comment
Share on other sites

  • 1 month later...

Hi,
any update on this? I'm really interested in using this method as i already have 2 urls, one for english and one for french content. I would give it a try but i would like to have more info on how to do it. Maybe you could post part of your script so i could understand it.

Many thanks

Link to comment
Share on other sites

Not much to post really.. you need two ftps, change the file classes/configuration.php
first line in “static public function get” (starts at line 89)

and just add this
if($key==‘PS_LANG_DEFAULT’) return 1; (Where 1 is the id of the language you want for the url pointing to this ftp)

Link to comment
Share on other sites

  • 1 year later...
  • 1 month later...

I have same problem as merinoexperten, the default language displayed on back office is Romanian but when i enter in the store its in English. The only solution i found is to disable English and keep Romanian as the only active language but im used to have backoffice in English so i really hope there is a fix.

P.S. i cleared all the browser cookies, temps, etc

Thank you!

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...