<?php require("date.inc.php3"); ?>
<select name="train_date">
<?php
$s_date=date("Y-m-d");
echo "<option value='$s_date'>$s_date</option>";
$today=mktime(0,0,0,date("m"),date("d"),date("Y"));
for ($i=1;$i<15;$i++){
$date=dateadd("day",$i,$today);
$s_date=date("Y-m-d",$date);
echo "<option value='$s_date'>$s_date</option>";
}
?>
</select>
文章来源于领测软件测试网 https://www.ltesting.net/