forked from extern/egroupware
fix for 2 people importing an equally named file at the same time, thanks to Matthew Galgoci <mgalgoci -at- redhat.com>
This commit is contained in:
parent
6881070b41
commit
d0b2a3a823
@ -21,7 +21,7 @@
|
||||
|
||||
if (isset($_FILES['csvfile']['tmp_name']))
|
||||
{
|
||||
$csvfile = $GLOBALS['phpgw_info']['server']['temp_dir'].'/addrbook_import_'.basename($csvfile);
|
||||
$csvfile = tempnam($GLOBALS['phpgw_info']['server']['temp_dir'],$GLOBALS['phpgw_info']['flags']['currentapp']."_");
|
||||
$GLOBALS['phpgw']->session->appsession('csvfile','',$csvfile);
|
||||
$_POST['action'] = move_uploaded_file($_FILES['csvfile']['tmp_name'],$csvfile) ?
|
||||
'download' : '';
|
||||
|
@ -25,7 +25,7 @@
|
||||
}
|
||||
if (isset($_FILES['csvfile']['tmp_name']))
|
||||
{
|
||||
$csvfile = $GLOBALS['phpgw_info']['server']['temp_dir'].'/calendar_import_'.basename($csvfile);
|
||||
$csvfile = tempnam($GLOBALS['phpgw_info']['server']['temp_dir'],$GLOBALS['phpgw_info']['flags']['currentapp']."_");
|
||||
$GLOBALS['phpgw']->session->appsession('csvfile','',$csvfile);
|
||||
$_POST['action'] = move_uploaded_file($_FILES['csvfile']['tmp_name'],$csvfile) ?
|
||||
'download' : '';
|
||||
|
@ -26,7 +26,7 @@
|
||||
}
|
||||
if (isset($_FILES['csvfile']['tmp_name']))
|
||||
{
|
||||
$csvfile = $GLOBALS['phpgw_info']['server']['temp_dir'].'/infolog_import_'.basename($csvfile);
|
||||
$csvfile = tempnam($GLOBALS['phpgw_info']['server']['temp_dir'],$GLOBALS['phpgw_info']['flags']['currentapp']."_");
|
||||
$GLOBALS['phpgw']->session->appsession('csvfile','',$csvfile);
|
||||
$_POST['action'] = move_uploaded_file($_FILES['csvfile']['tmp_name'],$csvfile) ?
|
||||
'download' : '';
|
||||
|
Loading…
Reference in New Issue
Block a user