hopefully bringing back the unread link for pages being read but having unread posts on subsequent pages

git-svn-id: file:///svn/phpbb/trunk@7312 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
Meik Sievertsen 2007-04-09 17:05:53 +00:00
parent 128be038da
commit c8b5adf506

View file

@ -1505,11 +1505,20 @@ else
} }
// If there are absolutely no more unread posts in this forum and unread posts shown, we can savely show the #unread link // If there are absolutely no more unread posts in this forum and unread posts shown, we can savely show the #unread link
if ($all_marked_read && $post_unread) if ($all_marked_read)
{ {
$template->assign_vars(array( if ($post_unread)
'U_VIEW_UNREAD_POST' => '#unread', {
)); $template->assign_vars(array(
'U_VIEW_UNREAD_POST' => '#unread',
));
}
else if (isset($topic_tracking_info[$topic_id]) && $topic_data['topic_last_post_time'] > $topic_tracking_info[$topic_id])
{
$template->assign_vars(array(
'U_VIEW_UNREAD_POST' => append_sid("{$phpbb_root_path}viewtopic.$phpEx", "f=$forum_id&t=$topic_id&view=unread") . '#unread',
));
}
} }
else if (!$all_marked_read) else if (!$all_marked_read)
{ {