php carbon format time hhHmm code example
Example 1: carbon two day ago
$dt =Carbon::now();
echo $dt->subDay(); // 2012-03-03 00:00:00
echo $dt->subDays(29);
Example 2: add seconds to datetime carbon
Try to parse() it first:
$date = Carbon::parse($dateTime)
->addSeconds($seconds)
->format('Y-m-d H:i:s');