diff options
author | Cflip <36554078+cflip@users.noreply.github.com> | 2021-01-23 12:25:51 -0700 |
---|---|---|
committer | Cflip <36554078+cflip@users.noreply.github.com> | 2021-01-23 12:25:51 -0700 |
commit | c23ad7cbf42f9590b4e0418b77c333f9dc7730e7 (patch) | |
tree | c3db1eef2d3db416579259f36dcdb3d2aef5ac8e /category.php | |
parent | 0b26a9cd485d5b1ed509d9da998780d8b658eb8a (diff) |
Change terminology from topics to threads
Diffstat (limited to 'category.php')
-rw-r--r-- | category.php | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/category.php b/category.php index b444ef3..fcc7851 100644 --- a/category.php +++ b/category.php @@ -27,21 +27,21 @@ mysqli_free_result($result); echo '</section>'; -$sql = "SELECT topic_id, topic_subject, topic_date, user_name FROM topics LEFT JOIN users ON topic_author = user_id WHERE topic_cat = " . mysqli_real_escape_string($dbc, $_GET['id']) . " ORDER BY topic_id DESC"; +$sql = "SELECT thread_id, thread_subject, thread_date, user_name FROM threads LEFT JOIN users ON thread_author = user_id WHERE thread_cat = " . mysqli_real_escape_string($dbc, $_GET['id']) . " ORDER BY thread_id DESC"; $result = mysqli_query($dbc, $sql); if (!$result) { - die('Error trying to display topics: ' . mysqli_error($dbc)); + die('Error trying to display threads: ' . mysqli_error($dbc)); } // Display table of posts -echo '<table><tr><th class="left">Topic</th><th class="right">Latest Post</th></tr>'; +echo '<table><tr><th class="left">Thread</th><th class="right">Latest Post</th></tr>'; while ($row = mysqli_fetch_assoc($result)) { echo '<tr><td class="left">'; - echo '<h4><a href="topic.php?id=' . $row['topic_id'] . '">' . $row['topic_subject'] . '</a></h4>'; - echo '<small>by <b>' . $row['user_name'] . '</b> on ' . date('M d, Y', strtotime($row['topic_date'])) . '</small></td><td class="right">by <b>cflip</b><br><small>01-22-2021 9:34</small></td></tr>'; + echo '<h4><a href="thread.php?id=' . $row['thread_id'] . '">' . $row['thread_subject'] . '</a></h4>'; + echo '<small>by <b>' . $row['user_name'] . '</b> on ' . date('M d, Y', strtotime($row['thread_date'])) . '</small></td><td class="right">by <b>cflip</b><br><small>01-22-2021 9:34</small></td></tr>'; } echo '</table>'; |