r905 - webspace/include
DONOTREPLY at icculus.org
DONOTREPLY at icculus.org
Wed Sep 13 14:41:04 EDT 2006
Author: floam
Date: 2006-09-13 14:41:04 -0400 (Wed, 13 Sep 2006)
New Revision: 905
Modified:
webspace/include/news.php
Log:
Problems
Modified: webspace/include/news.php
===================================================================
--- webspace/include/news.php 2006-09-13 07:08:36 UTC (rev 904)
+++ webspace/include/news.php 2006-09-13 18:41:04 UTC (rev 905)
@@ -40,13 +40,13 @@
$err = "Failed to grab news item: $err";
break;
}
- if (strpos($item['text'], "<p>") != 0)
- $item['text'] = "<p>" . $item['text'];
+ if (strpos(trim($item['text']), "<p>") !== 0)
+ $item['text'] = "<p>" . trim($item['text']);
if (strrpos(trim($item['text']), "</p>") != (strlen(trim($item['text'])) - 4))
$item['text'] .= "</p>";
- echo "<h3 id=\"post" . $item['id'] . "\">" . $item['title'] . " - <em>" .
+ echo "\n<h3 id=\"post" . $item['id'] . "\">" . $item['title'] . " - <em>" .
date("F j, Y", strtotime($item['postdate'])) . "</em></h3>\n" . $item['text'] .
- "<p><a class=\"permalink\" href=\"?page=news&news_item=" . $item['id'] . "\">Permalink</a></p>";
+ "\n<p><a class=\"permalink\" href=\"?page=news&news_item=" . $item['id'] . "\">Permalink</a></p>";
if ($current_post++ == $news_item_count - 1)
$lastid = $digestItem['id'];
}
More information about the quake3-commits
mailing list