- web: fix bug if news item title occurs in middle of content

svn path=/trunk/boinc/; revision=20004
This commit is contained in:
David Anderson 2009-12-21 19:38:50 +00:00
parent 37ea627866
commit 8132f29140
2 changed files with 80 additions and 74 deletions

View File

@ -10503,3 +10503,9 @@ David 21 Dec 2009
work_fetch.h
lib/
notice.cpp
David 21 Dec 2009
- web: fix bug if news item title occurs in middle of content
html/inc/
news.inc

View File

@ -61,7 +61,7 @@ function show_news($start, $count) {
foreach ($threads as $thread) {
$posts = BoincPost::enum("thread=$thread->id order by id limit 1");
$post = $posts[0];
if (strstr($post->content, $thread->title)) {
if (strstr($post->content, $thread->title) == $post->content) {
$title = null;
} else {
$title = $thread->title;