date_modify or DateTime::modify function modifies the timestamp of a DateTime object by incrementing or decrementing in a format accepted by strtotime(). It returns the modify date time.
public DateTime DateTime::modify ( string $modify )
DateTime date_modify ( DateTime $object , string $modify )
Parameters of Date Modify Function PHP
object - Procedural style only: A DateTime object returned by date_create()
modify - String in a relative format accepted by strtotime().
$date = new DateTime("2009-08-25");
If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.