mirror of
https://github.com/moodle/moodle.git
synced 2025-03-18 22:50:19 +01:00
MDL-61010 mod_forum: Add unread link to blog view
This commit is contained in:
parent
95b7be7f05
commit
600bd182fc
@ -3516,10 +3516,11 @@ function forum_print_post($post, $discussion, $forum, &$cm, $course, $ownpost=fa
|
||||
}
|
||||
if (!empty($discussion->unread) && $discussion->unread !== '-') {
|
||||
$replystring .= ' <span class="sep">/</span> <span class="unread">';
|
||||
$unreadlink = new moodle_url($discussionlink, null, 'unread');
|
||||
if ($discussion->unread == 1) {
|
||||
$replystring .= get_string('unreadpostsone', 'forum');
|
||||
$replystring .= html_writer::link($unreadlink, get_string('unreadpostsone', 'forum'));
|
||||
} else {
|
||||
$replystring .= get_string('unreadpostsnumber', 'forum', $discussion->unread);
|
||||
$replystring .= html_writer::link($unreadlink, get_string('unreadpostsnumber', 'forum', $discussion->unread));
|
||||
}
|
||||
$replystring .= '</span>';
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user