MDL-7734 fixed global $COURSE

This commit is contained in:
skodak
2008-02-04 21:12:45 +00:00
parent 7c3bf2a16b
commit 0dbc56ee8b
+3 -3
View File
@@ -5094,11 +5094,11 @@ function editorhelpbutton(){
*/
function helpbutton ($page, $title='', $module='moodle', $image=true, $linktext=false, $text='', $return=false,
$imagetext='') {
global $CFG, $course;
global $CFG, $COURSE;
// fix for MDL-7734
if (!empty($course->lang)) {
$forcelang = $course->lang;
if (!empty($COURSE->lang)) {
$forcelang = $COURSE->lang;
} else {
$forcelang = '';
}