diff options
Diffstat (limited to 'all.php')
-rw-r--r-- | all.php | 28 |
1 files changed, 28 insertions, 0 deletions
@@ -0,0 +1,28 @@ +<?php include_once 'header.php';?> + +<table> +<tr> + <th class="left">Latest Threads</th> + <th class="right">Latest Post</th> +</tr> + +<?php + +include_once 'includes/db_inc.php'; +include_once 'includes/functions_inc.php'; + +$sql = "SELECT thread_id, thread_subject, thread_date, user_id, user_name, cat_id, cat_name FROM threads JOIN users ON thread_author = user_id JOIN categories ON thread_cat = cat_id ORDER BY thread_id DESC"; +$result = mysqli_query($dbc, $sql); + +if (!$result) { + die('Error trying to display threads: ' . mysqli_error($dbc)); +} + +display_threads($dbc, $result, true); +mysqli_free_result($result); + +?> + +</table> + +<?php include_once 'footer.php';?>
\ No newline at end of file |