Vergleich inc/functions_upload.php - 1.4.0 - 1.4.1

  Keine Änderungen   Hinzugefügt   Modifiziert   Entfernt
Zeile 6Zeile 6
 * Website: http://www.mybboard.net
* License: http://www.mybboard.net/about/license
*

 * Website: http://www.mybboard.net
* License: http://www.mybboard.net/about/license
*

 * $Id: functions_upload.php 4036 2008-07-24 11:35:12Z ZiNgaBuRgA $

 * $Id: functions_upload.php 4101 2008-08-10 18:52:38Z Tikitiki $

 */



 */



Zeile 403Zeile 403
		{
$month_dir = '';
}

		{
$month_dir = '';
}

	}    








	}

// If safe_mode is enabled, don't attempt to use the monthly directories as it won't work
if(ini_get('safe_mode') == 1 || strtolower(ini_get('safe_mode')) == 'on')
{
$month_dir = '';
}


	// All seems to be good, lets move the attachment!
$filename = "post_".$mybb->user['uid']."_".TIME_NOW.".attach";

	// All seems to be good, lets move the attachment!
$filename = "post_".$mybb->user['uid']."_".TIME_NOW.".attach";

 
	

	$file = upload_file($attachment, $mybb->settings['uploadspath']."/".$month_dir, $filename);

	$file = upload_file($attachment, $mybb->settings['uploadspath']."/".$month_dir, $filename);

 
	
// Failed to create the attachment in the monthly directory, just throw it in the main directory
if($file['error'] && $month_dir)
{
$file = upload_file($attachment, $mybb->settings['uploadspath'].'/', $filename);
}


if($month_dir)
{


if($month_dir)
{

Zeile 555Zeile 569
		$upload['error'] = 2;
return $upload;
}

		$upload['error'] = 2;
return $upload;
}

	@my_chmod($path."/".$filename, 0644);

	@my_chmod($path."/".$filename, '0644');

	$upload['filename'] = $filename;
$upload['path'] = $path;
$upload['type'] = $file['type'];

	$upload['filename'] = $filename;
$upload['path'] = $path;
$upload['type'] = $file['type'];