Add setting of language to home page, and setting of new user accounts

to whatever the current language is.
This commit is contained in:
moodler
2003-01-20 08:01:46 +00:00
parent 0b949a6d0c
commit a5e3644bd2
2 changed files with 11 additions and 2 deletions
+10 -1
View File
@@ -22,9 +22,18 @@
$headerbutton = "<FONT SIZE=2><A HREF=\"$CFG->wwwroot/login/index.php\">".get_string("login")."</A></FONT>";
}
}
if (isset($lang)) {
$SESSION->lang = $lang;
save_session("SESSION");
}
$currlang = current_language();
$langs = get_list_of_languages();
$langmenu = popup_form ("$CFG->wwwroot/?lang=", $langs, "chooselang", $currlang, "", "", "", true);
print_header("$site->fullname", "$site->fullname", "home", "",
"<META NAME=\"Description\" CONTENT=\"".stripslashes(strip_tags($site->summary))."\">",
true, "", $headerbutton);
true, "", $headerbutton.$langmenu);
$firstcolumn = false; // for now
$side = 175;
+1 -1
View File
@@ -11,7 +11,7 @@
$user->password = md5($user->password);
$user->confirmed = 0;
$user->lang = $CFG->lang;
$user->lang = current_language();
$user->firstaccess = time();
$user->secret = random_string(15);