A
A
Alexander Andropov2019-03-28 10:51:45
PHP
Alexander Andropov, 2019-03-28 10:51:45

How to add 30 days to a date?

I get the date like this How to add + 30 days to this date so that a variable, for example date2, is equal to today's date + 30 days ahead?
$date = date("Y.m.d");

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Dmitry, 2019-03-28
@LongOf

Good morning.
echo date("Y.m.d", strtotime('+30 day'));

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question