website page counter

Php Minus Date

The best Images

Php Minus Date. Subtract 40 days from the 15th of march 2013. Note that passing in 12 months will also accomplish the exact same thing.

The Complete Guide To How To Publish An Ebook Kindle Publishing Amazon Kindle Books Amazon Kindle Publishing
The Complete Guide To How To Publish An Ebook Kindle Publishing Amazon Kindle Books Amazon Kindle Publishing from in.pinterest.com

Echo interval format in a days. If omitted the current date and time will be used as in the examples above. Subtract 40 days from the 15th of march 2013.

In the example above we set the dateinterval object to p1d which means a period of one day.

We then subtracted that interval from the current date. Echo interval format in a days. Let us imagine that it is may 31 2019 so 2019 05 31 the function will not give 2019 04 31. Date1 new datetime now.

close