Commit a5e3644b authored by moodler's avatar moodler
Browse files

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

to whatever the current language is.
parent 0b949a6d
......@@ -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;
......
......@@ -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);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment