php hari terakhir bulan
$a_date = "2009-11-23";
echo date("Y-m-t", strtotime($a_date));
Evil Echidna
$a_date = "2009-11-23";
echo date("Y-m-t", strtotime($a_date));
<?php
//Create DateTime object from specified date.
$date = new DateTime('2012-02-01');
//Print out your desired result by using
//the format method
echo $date->format('Y-m-t');
$lastDateOfMonth = date("Y-m-t", strtotime($dateString));