Pages

Thursday, March 25, 2010

osCommerce - default language issues

Recently an online shop using osCommerce 2.2 faced a problem:
Default language displayed was english even though in setup I used Romanian...

It seems that osCommerce checks browser language and displays that as default language. On way to solve this is:

if (isset($HTTP_GET_VARS['language']) && tep_not_null($HTTP_GET_VARS['language'])) {
      $lng->set_language($HTTP_GET_VARS['language']);
    } else {
      $lng->get_browser_language();
    }

Comment the line of code
//$lng->get_browser_language();
And you should have this solved.

1 comment:

Mariya said...

Very Important query in this post.
I always get this error. thanks to share solution of this error.


thanks

oscommerce developer