Skip to content

Commit

Permalink
gettext-changes/bugfixes
Browse files Browse the repository at this point in the history
git-svn-id: file:///Users/Shitiz/Downloads/lssvn/source/phpsurveyor@1816 b72ed6b6-b9f8-46b5-92b4-906544132732
  • Loading branch information
c-schmitz committed Jul 29, 2006
1 parent 007ea82 commit 3238229
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 7 deletions.
8 changes: 4 additions & 4 deletions classes/php-gettext/gettext.inc
Expand Up @@ -23,11 +23,11 @@
*/
/*
LC_CTYPE 0
LC_NUMERIC 1
LC_NUMERIC 1
LC_TIME 2
LC_COLLATE 3
LC_MONETARY 4
LC_MESSAGES 5
LC_COLLATE 3
LC_MONETARY 4
LC_MESSAGES 5
LC_ALL 6
*/

Expand Down
9 changes: 6 additions & 3 deletions common.php
Expand Up @@ -1675,9 +1675,12 @@ function GetLanguageFromSurveyID($surveyid)

function SetInterfaceLanguage($languagetoset)
{
//@$locale = (isset($_GET['lang']))? $_GET['lang'] : DEFAULT_LOCALE;
//if (function_exists('T_setlocale')) T_setlocale(LC_MESSAGES, $locale);
// echo setlocale(LC_ALL, $languagetoset);
@$locale = (isset($_GET['lang']))? $_GET['lang'] : DEFAULT_LOCALE;
if (function_exists('T_setlocale')) T_setlocale(LC_MESSAGES, $locale);
@setlocale(LC_ALL, $languagetoset);
@putenv("LANG=$languagetoset");
@putenv("LANGUAGE=$languagetoset");

bindtextdomain($languagetoset, dirname(__FILE__).'/locale');
if (!function_exists('bind_textdomain_codeset')) echo "You need at least PHP 4.2.x to run PHPSurveyor." and die;
bind_textdomain_codeset($languagetoset,'UTF-8');
Expand Down

0 comments on commit 3238229

Please sign in to comment.