date add one day php

41

php add days to date -

$start_date = "2015/03/02";  
$date = strtotime($start_date);
$date = strtotime("+7 day", $date);
echo date('Y/m/d', $date);

add 1 day php datetime -

$date = new DateTime('2000-01-01');
$date->add(new DateInterval('P1D'));

PHP Date add days -

$date = date('Y-m-d', strtotime("+1 day"));

Comments

Submit
0 Comments