Source Code:
(back to article)
<?php $date1 = "2022-01-01"; $date2 = "2022-01-31"; $timestamp1 = strtotime($date1); $timestamp2 = strtotime($date2); $diff = $timestamp2 - $timestamp1; echo $diff;
Result:
Report an issue