mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-10 02:36:38 +02:00
- use acl_m_ instead of acl_m
- some reference fixes git-svn-id: file:///svn/phpbb/trunk@5307 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
@@ -62,7 +62,7 @@ class filespec
|
||||
$this->mimetype = 'application/octetstream';
|
||||
}
|
||||
|
||||
$this->extension = array_pop(explode('.', strtolower($this->realname)));
|
||||
$this->extension = strtolower($this->get_extension($this->realname));
|
||||
|
||||
// Try to get real filesize from temporary folder (not always working) ;)
|
||||
$this->filesize = (@filesize($this->filename)) ? @filesize($this->filename) : $this->filesize;
|
||||
@@ -144,6 +144,20 @@ class filespec
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Get file extension
|
||||
*/
|
||||
function get_extension($filename)
|
||||
{
|
||||
if (strpos($filename, '.') === false)
|
||||
{
|
||||
return '';
|
||||
}
|
||||
|
||||
$filename = explode('.', $filename);
|
||||
return array_pop($filename);
|
||||
}
|
||||
|
||||
/**
|
||||
* Move file to destination folder
|
||||
*
|
||||
@@ -508,7 +522,11 @@ class fileupload
|
||||
$port = (!empty($url['port'])) ? (int) $url['port'] : 80;
|
||||
|
||||
$upload_ary['type'] = 'application/octet-stream';
|
||||
$upload_ary['name'] = basename($url['path']) . '.' . array_pop(explode('.', $url['path']));
|
||||
|
||||
$url['path'] = explode('.', $url['path']);
|
||||
$ext = array_pop($url['path']);
|
||||
|
||||
$upload_ary['name'] = basename($url['path']) . (($ext) ? '.' . $ext : '');
|
||||
$filename = $url['path'];
|
||||
$filesize = 0;
|
||||
|
||||
|
@@ -812,7 +812,10 @@ function mcp_fork_topic($topic_ids)
|
||||
$new_topic_id = $db->sql_nextid();
|
||||
$new_topic_id_list[$topic_id] = $new_topic_id;
|
||||
|
||||
markread('topic', $to_forum_id, $new_topic_id);
|
||||
/**
|
||||
* @todo enable
|
||||
* markread('topic', $to_forum_id, $new_topic_id);
|
||||
*/
|
||||
|
||||
if ($topic_row['poll_start'])
|
||||
{
|
||||
@@ -979,10 +982,10 @@ class mcp_main_info
|
||||
'title' => 'MCP_MAIN',
|
||||
'version' => '1.0.0',
|
||||
'modes' => array(
|
||||
'front' => array('title' => 'MCP_MAIN_FRONT', 'auth' => 'acl_m'),
|
||||
'forum_view' => array('title' => 'MCP_MAIN_FORUM_VIEW', 'auth' => 'acl_m'),
|
||||
'topic_view' => array('title' => 'MCP_MAIN_TOPIC_VIEW', 'auth' => 'acl_m'),
|
||||
'post_details' => array('title' => 'MCP_MAIN_POST_DETAILS', 'auth' => 'acl_m'),
|
||||
'front' => array('title' => 'MCP_MAIN_FRONT', 'auth' => 'acl_m_'),
|
||||
'forum_view' => array('title' => 'MCP_MAIN_FORUM_VIEW', 'auth' => 'acl_m_'),
|
||||
'topic_view' => array('title' => 'MCP_MAIN_TOPIC_VIEW', 'auth' => 'acl_m_'),
|
||||
'post_details' => array('title' => 'MCP_MAIN_POST_DETAILS', 'auth' => 'acl_m_'),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
Reference in New Issue
Block a user