Don't show users tab if you can't go there

This commit is contained in:
moodler
2006-06-19 13:51:58 +00:00
parent 0e83e4f5ca
commit 4d0036e8be
+6 -2
View File
@@ -34,8 +34,12 @@
print_heading($site->fullname);
if ($CFG->bloglevel >= 4) {
$toprow[] = new tabobject('participants', $CFG->wwwroot.'/user/index.php?id='.SITEID,
get_string('participants'));
if (isteacher(SITEID) ||
($CFG->showsiteparticipants == 1 && isteacherinanycourse()) ||
($CFG->showsiteparticipantslist == 2)) {
$toprow[] = new tabobject('participants', $CFG->wwwroot.'/user/index.php?id='.SITEID,
get_string('participants'));
}
$toprow[] = new tabobject('blogs', $CFG->wwwroot.'/blog/index.php?filtertype=site&',
get_string('blogs','blog'));