Can Carbon return number of days for a given year?
$dt = Carbon::parse($year . '-'. 1 .'-' . $from);
var_dump($dt->format('z') + 1 );
this does not seems to work
Can Carbon return number of days for a given year?
$dt = Carbon::parse($year . '-'. 1 .'-' . $from);
var_dump($dt->format('z') + 1 );
this does not seems to work
You can get by using carbon property
Carbon::parse('2020-01')->daysInYear //for year
Carbon::parse('2020-01')->daysInMonth //for month