summaryrefslogtreecommitdiff
path: root/mod.php
diff options
context:
space:
mode:
authorSavetheinternet <savetheinternet@n0v4.com>2011-02-18 00:44:01 +1100
committerSavetheinternet <savetheinternet@n0v4.com>2011-02-18 00:44:01 +1100
commit556e5bdcea99a443e9fba729f835be7cf488036f (patch)
tree6bc617b51e63a70c58aec9adaaf5fe2382b0431c /mod.php
parent4562843538a25dbb5d565943de59188cbfe60471 (diff)
Seperated threads and posts in the IP page
Diffstat (limited to 'mod.php')
-rw-r--r--mod.php7
1 files changed, 6 insertions, 1 deletions
diff --git a/mod.php b/mod.php
index bc162a9a..4b4046a9 100644
--- a/mod.php
+++ b/mod.php
@@ -656,9 +656,14 @@
$query->execute() or error(db_error($query));
while($post = $query->fetch()) {
- $po = new Post($post['id'], $post['thread'], $post['subject'], $post['email'], $post['name'], $post['trip'], $post['body'], $post['time'], $post['thumb'], $post['thumbwidth'], $post['thumbheight'], $post['file'], $post['filewidth'], $post['fileheight'], $post['filesize'], $post['filename'], $post['ip'], $mod ? '?/' : $config['root'], $mod);
+ if(!$post['thread']) {
+ $po = new Thread($post['id'], $post['subject'], $post['email'], $post['name'], $post['trip'], $post['body'], $post['time'], $post['thumb'], $post['thumbwidth'], $post['thumbheight'], $post['file'], $post['filewidth'], $post['fileheight'], $post['filesize'], $post['filename'], $post['ip'], $post['sticky'], $post['locked'], $mod ? '?/' : $config['root'], $mod);
+ } else {
+ $po = new Post($post['id'], $post['thread'], $post['subject'], $post['email'], $post['name'], $post['trip'], $post['body'], $post['time'], $post['thumb'], $post['thumbwidth'], $post['thumbheight'], $post['file'], $post['filewidth'], $post['fileheight'], $post['filesize'], $post['filename'], $post['ip'], $mod ? '?/' : $config['root'], $mod);
+ }
$temp .= $po->build();
}
+
if(!empty($temp))
$body .= '<fieldset><legend>Last ' . $query->rowCount() . ' posts on <a href="?/' .
sprintf($config['board_path'], $_board['uri']) . $config['file_index'] .