mirror of
https://github.com/moodle/moodle.git
synced 2025-04-15 05:25:08 +02:00
Fixed some recent buggy logic! Thanks, Eagle Eye!
This commit is contained in:
parent
b4a773610d
commit
c09e00ba62
@ -1636,9 +1636,9 @@ function print_header ($title='', $heading='', $navigation='', $focus='', $meta=
|
||||
if (substr($path, -1) == '/') {
|
||||
$path .= 'index';
|
||||
}
|
||||
if (empty($path) or $path = '/index') {
|
||||
if (empty($path) or $path == '/index') {
|
||||
$pageid = 'site-index';
|
||||
$pageclass = 'course course-'.SITEID;
|
||||
$pageclass = 'course';
|
||||
} else {
|
||||
$pageid = str_replace('/', '-', $path);
|
||||
$pageclass = explode('-', $pageid);
|
||||
@ -1648,6 +1648,8 @@ function print_header ($title='', $heading='', $navigation='', $focus='', $meta=
|
||||
|
||||
if (isset($course->id)) {
|
||||
$pageclass .= ' course-'.$course->id;
|
||||
} else {
|
||||
$pageclass .= ' course-'.SITEID;
|
||||
}
|
||||
|
||||
$bodytags .= ' class="'.$pageclass.'" id="'.$pageid.'"';
|
||||
|
Loading…
x
Reference in New Issue
Block a user