check current month from time in php code example
Example 1: php get current year
$currentYear=date("Y");//2019
Example 2: get month days in php
echo cal_days_in_month(CAL_GREGORIAN, 8, 2009);
$currentYear=date("Y");//2019
echo cal_days_in_month(CAL_GREGORIAN, 8, 2009);