Answers for "php date subtract 1 day"

PHP
1

php remove 1 day from date

print('Next Date ' . date('Y-m-d', strtotime('-1 day', strtotime($date_raw))));
Posted by: Guest on July-18-2020
0

php date format minus 1 day

date('Y-m-d',(strtotime ( '-1 day' , strtotime ( $date) ) ));
Posted by: Guest on September-05-2021
0

subtract some days php

// First date of the month.
$monthFirstDate = date('Y-m-01', strtotime('today'));

// Last date of the month.
$monthLastDate = date('Y-m-t', strtotime('today'));

// Second last date of the month
$monthLastSecondDate = date('Y-m-d', strtotime('-2 day', strtotime('today')));
Posted by: Guest on September-07-2021

Browse Popular Code Answers by Language