2007年7月17日 星期二

如何用PHP取得上個月的最後一天?

$temp = strtotime("-1 month", time());

echo "上月最後一天是".date("Y-m-t", $temp);

其他依此類推..

沒有留言: