diff options
| author | Meik Sievertsen <acydburn@phpbb.com> | 2004-07-09 12:31:33 +0000 |
|---|---|---|
| committer | Meik Sievertsen <acydburn@phpbb.com> | 2004-07-09 12:31:33 +0000 |
| commit | bdd1643a7d316bdeaeca564412b4f83cd40199fd (patch) | |
| tree | 1e9a11bb9e84062bb04c83f0b150aeca1b44a866 /phpBB/includes/mcp/mcp_post.php | |
| parent | e083255f661573641167afd52f5c41a0588e49d3 (diff) | |
| download | forums-bdd1643a7d316bdeaeca564412b4f83cd40199fd.tar forums-bdd1643a7d316bdeaeca564412b4f83cd40199fd.tar.gz forums-bdd1643a7d316bdeaeca564412b4f83cd40199fd.tar.bz2 forums-bdd1643a7d316bdeaeca564412b4f83cd40199fd.tar.xz forums-bdd1643a7d316bdeaeca564412b4f83cd40199fd.zip | |
- added splitting of topics to mcp
- added merging of posts to mcp
- fixed parsing of acl_getf results
- adjusted tracking code for important announcements (seems to work now)
git-svn-id: file:///svn/phpbb/trunk@4923 89ea8834-ac86-4346-8a33-228a782c2dd0
Diffstat (limited to 'phpBB/includes/mcp/mcp_post.php')
| -rw-r--r-- | phpBB/includes/mcp/mcp_post.php | 33 |
1 files changed, 32 insertions, 1 deletions
diff --git a/phpBB/includes/mcp/mcp_post.php b/phpBB/includes/mcp/mcp_post.php index c1ecd3325b..00570964a8 100644 --- a/phpBB/includes/mcp/mcp_post.php +++ b/phpBB/includes/mcp/mcp_post.php @@ -84,6 +84,35 @@ function mcp_post_details($id, $mode, $action, $url) ); break; + case 'chgposter': + + $new_user = request_var('u', 0); + + if ($new_user && $auth->acl_get('m_', $post_info['forum_id']) && $new_user != $post_info['user_id']) + { + $sql = 'UPDATE ' . POSTS_TABLE . " + SET poster_id = $new_user + WHERE post_id = $post_id"; + $db->sql_query($sql); + + if ($post_info['topic_last_post_id'] == $post_info['post_id'] || $post_info['forum_last_post_id'] == $post_info['post_id']) + { + sync('topic', 'topic_id', $post_info['topic_id'], false, false); + sync('forum', 'forum_id', $post_info['forum_id'], false, false); + } + + // Renew post info + $post_info = get_post_data(array($post_id)); + + if (!sizeof($post_info)) + { + trigger_error($user->lang['POST_NOT_EXIST']); + } + + $post_info = $post_info[$post_id]; + } + break; + default: } @@ -215,4 +244,6 @@ function mcp_post_details($id, $mode, $action, $url) } } -}
\ No newline at end of file +} + +?>
\ No newline at end of file |
