aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/posting.php
diff options
context:
space:
mode:
authorMeik Sievertsen <acydburn@phpbb.com>2003-09-08 07:05:29 +0000
committerMeik Sievertsen <acydburn@phpbb.com>2003-09-08 07:05:29 +0000
commit924684b000a12f1089903eb0ef1c74dc05e1be53 (patch)
tree80d775c2200fbe548316ad1524ad560f12cdb41a /phpBB/posting.php
parent9dc398f3020b099c8aa32ff11c1e7e72e33f39d4 (diff)
downloadforums-924684b000a12f1089903eb0ef1c74dc05e1be53.tar
forums-924684b000a12f1089903eb0ef1c74dc05e1be53.tar.gz
forums-924684b000a12f1089903eb0ef1c74dc05e1be53.tar.bz2
forums-924684b000a12f1089903eb0ef1c74dc05e1be53.tar.xz
forums-924684b000a12f1089903eb0ef1c74dc05e1be53.zip
small things... decode_text now checks for bbcode_uid existence. And yes, i know i have screwed up a lot of posts. :/
git-svn-id: file:///svn/phpbb/trunk@4486 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/posting.php')
-rw-r--r--phpBB/posting.php17
1 files changed, 9 insertions, 8 deletions
diff --git a/phpBB/posting.php b/phpBB/posting.php
index 56d0cefc07..c79edcebc1 100644
--- a/phpBB/posting.php
+++ b/phpBB/posting.php
@@ -285,7 +285,7 @@ if ($mode == 'edit' && $post_edit_locked && !$auth->acl_get('m_', $forum_id))
if ($mode == 'edit')
{
- $message_parser->bbcode_uid = $row['bbcode_uid'];
+ $message_parser->bbcode_uid = $bbcode_uid;
}
@@ -423,7 +423,7 @@ if ($submit || $preview || $refresh)
}
$message_parser->message = (!empty($_POST['message'])) ? htmlspecialchars(trim(str_replace(array('\\\'', '\\"', '\\0', '\\\\'), array('\'', '"', '\0', '\\'), $_POST['message']))) : '';
-
+
$username = (!empty($_POST['username'])) ? trim($_POST['username']) : ((!empty($username)) ? $username : '');
$topic_type = (!empty($_POST['topic_type'])) ? (int) $_POST['topic_type'] : (($mode != 'post') ? $topic_type : POST_NORMAL);
$icon_id = (!empty($_POST['icon'])) ? (int) $_POST['icon'] : 0;
@@ -806,7 +806,6 @@ if (!sizeof($error) && $preview)
// Decode text for message display
$bbcode_uid = ($mode == 'quote' && !$preview) ? $row['bbcode_uid'] : $message_parser->bbcode_uid;
-
decode_text($post_text, $bbcode_uid);
if ($subject)
{
@@ -1732,11 +1731,14 @@ function submit_post($mode, $message, $subject, $username, $topic_type, $bbcode_
case 'edit_first_post':
case 'edit':
- $sql_data['post']['sql'] = array(
- 'post_edit_time' => $current_time
- );
+ if (!$auth->acl_gets('m_', 'a_'))
+ {
+ $sql_data['post']['sql'] = array(
+ 'post_edit_time' => $current_time
+ );
- $sql_data['post']['stat'][] = 'post_edit_count = post_edit_count + 1';
+ $sql_data['post']['stat'][] = 'post_edit_count = post_edit_count + 1';
+ }
case 'edit_topic':
case 'edit_last_post':
@@ -1880,7 +1882,6 @@ function submit_post($mode, $message, $subject, $username, $topic_type, $bbcode_
unset($sql_data['post']['sql']);
}
- // Now only updates are performed to the topics and posts table
// Update the topics table
if (isset($sql_data['topic']['sql']))
{