<input type="date" name ="date1">
然后
$DATE1 = (isset($_POST["date1"]) ? $_POST["date1"] : null);
这不会得到价值?
答案 0 :(得分:0)
<?php
if(isset($_POST) && !empty($_POST)){
if(!empty($_POST['date'])){
$date = $_POST['date'];
}
}
?>
<form action="" method="POST">
<label>Date : </label>
<input type="date" name="date"/>
<input type="submit" value="submit" />
</form>