mirror of
https://github.com/moodle/moodle.git
synced 2025-08-05 08:56:36 +02:00
fixed typos in chat_force_language(), added encoding to message page, minor cleanup
This commit is contained in:
parent
9a9ebde280
commit
a776c371e7
4 changed files with 14 additions and 5 deletions
|
@ -17,7 +17,6 @@
|
|||
?>
|
||||
<script type="text/javascript">
|
||||
<!--
|
||||
scroll_active = true;
|
||||
function empty_field_and_submit() {
|
||||
document.sendForm.chat_message.value = document.inputForm.chat_message.value;
|
||||
document.inputForm.chat_message.value = '';
|
||||
|
|
|
@ -1,2 +1,4 @@
|
|||
<html>
|
||||
<body>
|
||||
<html>
|
||||
<body>
|
||||
</body>
|
||||
</html>
|
||||
|
|
|
@ -49,6 +49,12 @@
|
|||
<meta http-equiv="content-type" content="text/html; charset=<?php echo get_string('thischarset'); ?>" />
|
||||
<script type="text/javascript">
|
||||
<!--
|
||||
if (parent.msg.document.getElementById("msgStarted") == null) {
|
||||
parent.msg.document.open("text/html","replace");
|
||||
parent.msg.document.write("<html><head>");
|
||||
parent.msg.document.write("<meta http-equiv=\"content-type\" content=\"text/html; charset=<?php echo get_string('thischarset'); ?>\" />");
|
||||
parent.msg.document.write("</head><body><div style=\"display: none\" id=\"msgStarted\"> </div>");
|
||||
}
|
||||
<?php
|
||||
$beep = false;
|
||||
$refreshusers = false;
|
||||
|
|
|
@ -295,11 +295,13 @@ function chat_force_language($lang) {
|
|||
/// This function prepares moodle to operate in given language
|
||||
/// usable when $nomoodlecookie = true;
|
||||
/// BEWARE: there must be no $course, $USER or $SESSION
|
||||
global $CFG;
|
||||
|
||||
if(!empty($CFG->courselang)) {
|
||||
uset($CFG->courselang);
|
||||
unset($CFG->courselang);
|
||||
}
|
||||
if(!empty($CFG->locale)) {
|
||||
uset($CFG->locale);
|
||||
unset($CFG->locale);
|
||||
}
|
||||
$CFG->lang = clean_filename($lang);
|
||||
moodle_setlocale();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue