我试图重命名一个文件,当我调用rename()函数时,文件get被重命名但它仍然给我错误"文件名uploads / 09-12-2015.xls不可读& #34;
date_default_timezone_set('America/Chicago');
/** Include path **/
set_include_path(get_include_path() . PATH_SEPARATOR . '../../../Classes/');
include 'lib/Classes/PHPExcel/IOFactory.php';
/** PHPExcel_IOFactory */
include 'connect.php';
if (isset($_POST['config']))
{
$hotelName = $_POST['shortname'];
$reportDate = $_POST['reportDate'];
$dateCol = $_POST['dateCol'];
$dateRow = $_POST['dateRow'];
$soldCol = $_POST['soldCol'];
$revCol = $_POST['revCol'];
$todayDate = date('m-d-Y');
rename("uploads/$todayDate.xls","uploads/$reportDate.xls");
echo "done";
//$objPHPExcel = PHPExcel_IOFactory::load($inputFileName);
//$sheetData = $objPHPExcel->getActiveSheet()->toArray(null,true,true,true);
}