PHP8.1 Syntax/Functionality Changes & Deprecations List Check

This commit is contained in:
kjh
2022-05-24 08:44:52 +00:00
parent 0b90f9d631
commit 0edbdab1d8
3 changed files with 10 additions and 10 deletions

View File

@ -534,7 +534,7 @@ class PHPExcel_Calculation_DateTime
if ($testVal2 !== false) {
$testVal3 = strtok('- ');
if ($testVal3 === false) {
$testVal3 = strftime('%Y');
$testVal3 = date('Y');
}
} else {
return PHPExcel_Calculation_Functions::VALUE();
@ -554,16 +554,16 @@ class PHPExcel_Calculation_DateTime
if (($PHPDateArray !== false) && ($PHPDateArray['error_count'] == 0)) {
// Execute function
if ($PHPDateArray['year'] == '') {
$PHPDateArray['year'] = strftime('%Y');
$PHPDateArray['year'] = date('Y');
}
if ($PHPDateArray['year'] < 1900) {
return PHPExcel_Calculation_Functions::VALUE();
}
if ($PHPDateArray['month'] == '') {
$PHPDateArray['month'] = strftime('%m');
$PHPDateArray['month'] = date('m');
}
if ($PHPDateArray['day'] == '') {
$PHPDateArray['day'] = strftime('%d');
$PHPDateArray['day'] = date('d');
}
$excelDateValue = floor(
PHPExcel_Shared_Date::FormattedPHPToExcel(