I have a date given as a string. And I would like to get the first monday after this given date, again as a string.
$myDate = \"2014-08-24\"; // date given i
You can do it using the DateTime and DateTime::modify
$date = new DateTime('2014-08-24'); $date->modify('next monday'); echo $date->format('Y-m-d') . "\n";