mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-28 06:08:52 +00:00
Ok one last attempt on my part to fix file upload bugs.. Might actually work (Hey it could happen, even I get one right occasionally)
git-svn-id: file:///svn/phpbb/trunk@2296 89ea8834-ac86-4346-8a33-228a782c2dd0
This commit is contained in:
parent
efc74bc4f0
commit
1db4b1fc44
3 changed files with 24 additions and 3 deletions
|
@ -32,7 +32,14 @@ if( !empty($setmodules) )
|
|||
{
|
||||
$filename = basename(__FILE__);
|
||||
$module['General']['Backup_DB'] = $filename . "?perform=backup";
|
||||
$file_uploads = get_cfg_var('file_uploads');
|
||||
if(phpversion() >= '4.0.0')
|
||||
{
|
||||
$file_uploads = ini_get('file_uploads');
|
||||
}
|
||||
else
|
||||
{
|
||||
$file_uploads = get_cfg_var('file_uploads');
|
||||
}
|
||||
if( ($file_uploads != 0 || empty($file_uploads)) && (strtolower($file_uploads) != 'off') && (phpversion() != '4.0.4pl1') )
|
||||
{
|
||||
$module['General']['Restore_DB'] = $filename . "?perform=restore";
|
||||
|
|
|
@ -983,7 +983,14 @@ if( $mode == "edit" || $mode == "save" && ( isset($HTTP_POST_VARS['username']) |
|
|||
// Let's do an overall check for settings/versions which would prevent
|
||||
// us from doing file uploads....
|
||||
//
|
||||
$file_uploads = get_cfg_var('file_uploads');
|
||||
if(phpversion() >= '4.0.0')
|
||||
{
|
||||
$file_uploads = ini_get('file_uploads');
|
||||
}
|
||||
else
|
||||
{
|
||||
$file_uploads = get_cfg_var('file_uploads');
|
||||
}
|
||||
if( ($file_uploads == 0 && !empty($file_uploads)) || (strtolower($file_uploads) == 'off') || (phpversion() == '4.0.4pl1') || (!$board_config['allow_avatar_upload']) )
|
||||
{
|
||||
$form_enctype = '';
|
||||
|
|
|
@ -1493,7 +1493,14 @@ if( isset($HTTP_GET_VARS['mode']) || isset($HTTP_POST_VARS['mode']) )
|
|||
// Let's do an overall check for settings/versions which would prevent
|
||||
// us from doing file uploads....
|
||||
//
|
||||
$file_uploads = get_cfg_var('file_uploads');
|
||||
if( phpversion() >= '4.0.0 )
|
||||
{
|
||||
$file_uploads = ini_get('file_uploads');
|
||||
}
|
||||
else
|
||||
{
|
||||
$file_uploads = get_cfg_var('file_uploads');
|
||||
}
|
||||
if( ($file_uploads == 0 && !empty($file_uploads)) || (strtolower($file_uploads) == 'off')|| (phpversion() == '4.0.4pl1') || (!$board_config['allow_avatar_upload']) )
|
||||
{
|
||||
$form_enctype = '';
|
||||
|
|
Loading…
Add table
Reference in a new issue