Post by Heilong » Wed Dec 10, 2008 5:37 pm

Hi everyone,

I need to modify the way to witch from a language to another one, because my online shop will be part of an existing website. On that website the language can be switch from the homepage, then a variable in the URL "index.php?lang=cn" define the language to display.

Under OC the way to switch language is a button on the homepage which is a part of a form sending the language value on OC homepage, is there any way to change this and take the URL value as language value for the shopping cart part of that website.

any suggestions,

Thanks for help,

New member

Posts

Joined
Mon Sep 01, 2008 5:57 pm

Post by bruce » Wed Dec 10, 2008 5:57 pm

Try the following in __construct in library\language\language.php at the beginning of the language detection code.

Code: Select all

		if (array_key_exists($this->request->get('lang', 'get'), $this->languages))
		{
			$this->set($this->request->get('lang', 'get'));
		}  
		elseif (array_key_exists($this->session->get(....
 		{
etc etc


Active Member

Posts

Joined
Wed Dec 12, 2007 2:26 pm

Post by Heilong » Thu Dec 11, 2008 10:35 am

Hi Bruce,

it's working  ;D

Thanks

New member

Posts

Joined
Mon Sep 01, 2008 5:57 pm
Who is online

Users browsing this forum: No registered users and 4 guests