aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/posting.php
diff options
context:
space:
mode:
Diffstat (limited to 'phpBB/posting.php')
-rw-r--r--phpBB/posting.php10
1 files changed, 7 insertions, 3 deletions
diff --git a/phpBB/posting.php b/phpBB/posting.php
index 59476ccf1b..0e1be3f711 100644
--- a/phpBB/posting.php
+++ b/phpBB/posting.php
@@ -495,6 +495,10 @@ if (isset($post))
$db->sql_query($sql);
}
+ // Mark this topic as read and posted to.
+ $mark_mode = ($mode == 'reply' || $mode == 'newtopic') ? 'post' : 'topic';
+ markread($mark_mode, $forum_id, $topic_id, $post_id);
+
$db->sql_transaction('commit');
$template->assign_vars(array(
@@ -503,7 +507,7 @@ if (isset($post))
$message = (!empty($enable_moderate)) ? 'POST_STORED_MOD' : 'POST_STORED';
trigger_error($user->lang[$message]);
- }
+ } // Store message, sync counters
// Houston, we have an error ...
$post_text = &stripslashes($message);
@@ -514,7 +518,7 @@ if (isset($post))
$template->assign_vars(array(
'ERROR_MESSAGE' => $err_msg)
);
-}
+} // isset($post)
// PROCESS SUBMIT
// --------------
@@ -885,4 +889,4 @@ function topic_review($topic_id, $is_inline_review = false)
}
}
-?> \ No newline at end of file
+?>