aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/includes/message_parser.php
diff options
context:
space:
mode:
authorNathaniel Guse <nathaniel.guse@gmail.com>2012-11-11 04:42:06 -0600
committerNathaniel Guse <nathaniel.guse@gmail.com>2012-11-11 04:42:06 -0600
commit84ba10ec8c023ab307eb7d0b829ab337aaaae78e (patch)
tree468abf9fbb513cba53803ca29c6b65fd4ea497ec /phpBB/includes/message_parser.php
parent106daa09ebb5b12bf9892c41f8c1de627cf6b0e9 (diff)
parente86ecc0f3bd6383d31a670896720a970b8faaaa9 (diff)
downloadforums-84ba10ec8c023ab307eb7d0b829ab337aaaae78e.tar
forums-84ba10ec8c023ab307eb7d0b829ab337aaaae78e.tar.gz
forums-84ba10ec8c023ab307eb7d0b829ab337aaaae78e.tar.bz2
forums-84ba10ec8c023ab307eb7d0b829ab337aaaae78e.tar.xz
forums-84ba10ec8c023ab307eb7d0b829ab337aaaae78e.zip
Merge branch 'develop' of github.com:EXreaction/phpbb3 into ticket/11103
Diffstat (limited to 'phpBB/includes/message_parser.php')
-rw-r--r--phpBB/includes/message_parser.php5
1 files changed, 3 insertions, 2 deletions
diff --git a/phpBB/includes/message_parser.php b/phpBB/includes/message_parser.php
index 6695047b56..1cd2a46fa1 100644
--- a/phpBB/includes/message_parser.php
+++ b/phpBB/includes/message_parser.php
@@ -1363,13 +1363,14 @@ class parse_message extends bbcode_firstpass
*/
function parse_attachments($form_name, $mode, $forum_id, $submit, $preview, $refresh, $is_message = false)
{
- global $config, $auth, $user, $phpbb_root_path, $phpEx, $db;
+ global $config, $auth, $user, $phpbb_root_path, $phpEx, $db, $request;
$error = array();
$num_attachments = sizeof($this->attachment_data);
$this->filename_data['filecomment'] = utf8_normalize_nfc(request_var('filecomment', '', true));
- $upload_file = (isset($_FILES[$form_name]) && $_FILES[$form_name]['name'] != 'none' && trim($_FILES[$form_name]['name'])) ? true : false;
+ $upload = $request->file($form_name);
+ $upload_file = (!empty($upload) && $upload['name'] !== 'none' && trim($upload['name']));
$add_file = (isset($_POST['add_file'])) ? true : false;
$delete_file = (isset($_POST['delete_file'])) ? true : false;