Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

No Automatic Language Selection


desa80

Recommended Posts

Posted

How to change the code, so osc NOT to select language according to language settings of user's browser but to use the Default - English?

May be i must edit application_top.php, but i don't know how? :

 

// set the language
 if (!tep_session_is_registered('language') || isset($HTTP_GET_VARS['language'])) {
   if (!tep_session_is_registered('language')) {
     tep_session_register('language');
     tep_session_register('languages_id');
   }

   include(DIR_WS_CLASSES . 'language.php');
   $lng = new language();

   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();
   }

   $language = $lng->language['directory'];
   $languages_id = $lng->language['id'];
 }

Posted

I am not sure how to do it but you could try just changing the else statement to the same as the if?

 

I mean change

 

$lng->get_browser_language();

to

$lng->set_language($HTTP_GET_VARS['language']);

probably not right, i am guessing here but worth a shot if you have a way to test it.

Wendy James

 

Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...