Tag: calendar
-
简单日历程序
刚开始学程序设计那会儿写的,拿出来留恋一下。呵呵! <form action=”rili.php” enctype=”application/x-www-form-urlencoded” method=”post”> 月份 <select multiple=”65535″ name=”mon” size=”0″> <option value=”‘.$m.'”>’.$m.'</option> </select> 年份 <?php echo ‘<input size=”5″ name=”year” type=”text” value=”‘.date(Y).'”>’; ?> <input name=”Submit” type=”submit” value=”提交” /> <input name=”Submit2″ type=”reset” value=”重置” /> </form> <?php date_default_timezone_set(‘UTC’);//自动获取当地的时区 $mon=$_POST[‘mon’]; $year=$_POST[‘year’]; $a=mktime(0,0,0,$mon,01,$year); $daynum = date(t,$a);//一共28天 , $firstday=date(w,$a);//第一天是星期4, echo $daynum .” – “; echo $firstday; echo ‘<div style=”border:#FF6600 solid 1px;…