php last day of month
snippet in php

php last day of month

user8957

$a_date = "2009-11-23";
echo date("Y-m-t", strtotime($a_date));

check if is the last day of the month php

user5289

if(gmdate('t') == gmdate('d')){
    echo 'Last day of the month.';
}