The calculation formula for accumulating the total number of seconds in each month: the timestamp seconds on the 1st of the previous month minus the number of seconds in the current month Timestamp seconds
*/
$d[$i] = trim(date('Y-m',$t),' ');
$t += strtotime('+1 month', $t)- $t;
$i++;
}
return $d;
}
?>
Copy code
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn