diff options
Diffstat (limited to 'viewthread.php')
-rwxr-xr-x | viewthread.php | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/viewthread.php b/viewthread.php index 06debe8..d0a387e 100755 --- a/viewthread.php +++ b/viewthread.php @@ -27,13 +27,12 @@ if (!$current->has_value()) { <meta property="og:title" content="<?= $current->subject; ?>">
<meta property="og:url" content="https://forum.cflip.net/viewthread.php?id=<?= $current->id; ?>">
<meta property="og:type" content="article">
- <meta property="article:section" content="<?= $current->category->name; ?>">
</head>
<body>
<?php include_once 'includes/templates/header.php'; ?>
<h1><?= $current->subject; ?></h1>
- created by <b><?= $current->author->name; ?></b>
- in <b><?= $current->category->name; ?></b>, <?= date('M d, Y g:ia', strtotime($current->date_created)); ?>
+ created by <b><?= $current->get_author()->name; ?></b>
+ in <b><?= $current->get_parent_category()->name; ?></b>, <?= date('M d, Y g:ia', strtotime($current->date_created)); ?>
<?php if (Session::get()->is_signed_in() and Session::get()->get_current_user()->level == USER_LEVEL_MODERATOR): ?>
<a href="moderate.php?type=thread&id=<?= $current->id; ?>">Moderator Options</a>
<?php endif ?>
@@ -59,7 +58,7 @@ if ($_SERVER['REQUEST_METHOD'] == 'POST') { if (empty($post_content) or !$post_content) {
trigger_error('Reply cannot be empty');
} else {
- Post::create($post_content, $current->id, $current->category->id);
+ Post::create($post_content, $current->id, $current->category_id);
header('Location: ' . $_SERVER['PHP_SELF'] . '?id=' . $current->id);
}
}
|