Skip to content

Commit

Permalink
Make sure that the Site never shows up in My Courses
Browse files Browse the repository at this point in the history
  • Loading branch information
moodler committed Aug 26, 2003
1 parent 7cdcb42 commit c81696e
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions course/lib.php
Expand Up @@ -1004,6 +1004,9 @@ function print_courses_sideblock($category=0, $width="100%") {
if (isset($USER->id) and !isadmin()) { // Just print My Courses
if ($courses = get_my_courses($USER->id)) {
foreach ($courses as $course) {
if (!$course->category) {
continue;
}
$linkcss = $course->visible ? "" : " class=\"dimmed\" ";
$moddata[]="<a $linkcss title=\"$course->shortname\" ".
"href=\"$CFG->wwwroot/course/view.php?id=$course->id\">$course->fullname</a>";
Expand Down Expand Up @@ -1156,6 +1159,9 @@ function print_my_moodle() {

if ($courses = get_my_courses($USER->id)) {
foreach ($courses as $course) {
if (!$course->category) {
continue;
}
print_course($course, "100%");
echo "<br />\n";
}
Expand Down

0 comments on commit c81696e

Please sign in to comment.