本文实例讲述了php实现的日历程序。分享给大家供大家参考。具体如下: <?php ////判断$Year和$Month是否为空,如果为空就获取系统当前日期,否则用$_GET获取 $Year = empty($_GET['Year']) ? date("Y"): $_GET["Year"]; $Month = empty($_GET['Month']) ? date("m"): $_GET["Month"]; ////获取当前日期//// $Today = date("Ymj"); ////初始化日期数组//// $Maxday = array("1","2","3","4","5","