require("$_SERVER[DOCUMENT_ROOT]/lib/header.inc.php");
$currHeader->setPageTitle("Riptide Gaming - Read Message");
$currBanner->addContent("Read Message");
?>
$query = "SELECT postindex, threadid, anonymousid, date, subject, posttype, body, username FROM riptide_posts, riptide_users WHERE riptide_users.userindex = riptide_posts.posterid AND postindex = $_REQUEST[id] ORDER BY threadid ASC, threadorder ASC";
$result = mysql_query($query);
$row = mysql_fetch_array($result);
print("
$row[subject]
\n");
print("Author: $row[username] ($row[anonymousid])\n
Date: $row[date]
\n");
print("$row[body]");
print("
\n");
$query = "SELECT postindex, threadid, threadorder, replylevel, anonymousid, date, subject, posttype, username FROM riptide_posts, riptide_users WHERE riptide_users.userindex = riptide_posts.posterid AND threadid = $row[threadid] ORDER BY threadid ASC, threadorder ASC";
$result = mysql_query($query);
while ($row = mysql_fetch_array($result))
{
print("
");
for ($i = 0; $i < $row["replylevel"]; $i++) print("-");
print("$row[subject] - $row[username] - $row[date]\n");
}
?>
require("$_SERVER[DOCUMENT_ROOT]/lib/footer.inc.php");
?>