<?php $years = 5; $baseDate = new \DateTime(); $baseDate = new \DateTime($baseDate->format('Y-m-01 00:00:00')); $baseDate->modify('-' . $years . ' years'); var_dump($baseDate);
You have javascript disabled. You will not be able to edit any code.