diff --git a/html/forum/forum.php b/html/forum/forum.php index 09f77cf249..a4b1ad7463 100644 --- a/html/forum/forum.php +++ b/html/forum/forum.php @@ -2,6 +2,8 @@ require_once('../include.php'); require_once('forum.inc'); +define("EXCERPT_LENGTH", "120"); + // Number of forum topics per page. $n = 50; @@ -114,9 +116,11 @@ endif; $threads = $forum->getThreads($_GET['start'], $n, $sort_style); while($thread = getNextThread($threads)): $user = getUser($thread->owner); + $first_post = getFirstPost($thread->id); + $excerpt = sub_sentence($first_post->content, ' ', EXCERPT_LENGTH, true); ?> - title) ?> + title) ?>
is_helpdesk) { echo stripslashes($excerpt); } ?> is_helpdesk) { echo "", $thread->replies, "";