mirror of
https://github.com/moodle/moodle.git
synced 2025-04-21 00:12:56 +02:00
Some refinements to the display of forums
- don't show intro box for teacher forum (because it can't be edited) - don't show intro box when the text is empty anyway
This commit is contained in:
parent
1ddf93298b
commit
c6ee38d073
@ -133,14 +133,24 @@
|
||||
break;
|
||||
|
||||
case "eachuser":
|
||||
print_simple_box(text_to_html($forum->intro), "CENTER");
|
||||
echo "<P ALIGN=CENTER>";
|
||||
if (!empty($forum->intro)) {
|
||||
print_simple_box(text_to_html($forum->intro), "center");
|
||||
}
|
||||
echo "<p align=\"center\">";
|
||||
if (forum_user_can_post_discussion($forum)) {
|
||||
print_string("allowsdiscussions", "forum");
|
||||
} else {
|
||||
echo " ";
|
||||
}
|
||||
echo "</P>";
|
||||
echo "</p>";
|
||||
if (!empty($showall)) {
|
||||
forum_print_latest_discussions($forum->id, 0, "header");
|
||||
} else {
|
||||
forum_print_latest_discussions($forum->id, FORUM_MANY_DISCUSSIONS, "header");
|
||||
}
|
||||
break;
|
||||
|
||||
case "teacher":
|
||||
if (!empty($showall)) {
|
||||
forum_print_latest_discussions($forum->id, 0, "header");
|
||||
} else {
|
||||
@ -149,8 +159,10 @@
|
||||
break;
|
||||
|
||||
default:
|
||||
print_simple_box(text_to_html($forum->intro), "CENTER");
|
||||
echo "<P> </P>";
|
||||
if (!empty($forum->intro)) {
|
||||
print_simple_box(text_to_html($forum->intro), "center");
|
||||
}
|
||||
echo "<p> </p>";
|
||||
if (!empty($showall)) {
|
||||
forum_print_latest_discussions($forum->id, 0, "header");
|
||||
} else {
|
||||
|
Loading…
x
Reference in New Issue
Block a user