<!doctype html>
<html>
<head>
<style>
</style>
<script>
function test(){
var test1=document.getElementById("test1").value;
var test2=document.getElementById("test2").value;
var test3=document.getElementById("test3");
var test4="您预约的考试时间是:"+test1+" "+test2+" 请准时参加考试";
test3.innerHTML=test4;
}
</script>
<meta charset="UTF-8">
</head>
<body>
请选择预约考试时间:<input type="date" min="2012-01-01" max="2018-01-01" value="2017-11-12" id="test1"><!--min 和max属性设置上下限 日期的value值是xxxx-xx-xx 时间的value值是xx:xx-->
<input type="time" min="08:00" max="16:00" value="08:00" id="test2">
<button οnclick="test()">提交</button>
<p><span id="test3"></span></p>
</body>
</html>
<html>
<head>
<style>
</style>
<script>
function test(){
var test1=document.getElementById("test1").value;
var test2=document.getElementById("test2").value;
var test3=document.getElementById("test3");
var test4="您预约的考试时间是:"+test1+" "+test2+" 请准时参加考试";
test3.innerHTML=test4;
}
</script>
<meta charset="UTF-8">
</head>
<body>
请选择预约考试时间:<input type="date" min="2012-01-01" max="2018-01-01" value="2017-11-12" id="test1"><!--min 和max属性设置上下限 日期的value值是xxxx-xx-xx 时间的value值是xx:xx-->
<input type="time" min="08:00" max="16:00" value="08:00" id="test2">
<button οnclick="test()">提交</button>
<p><span id="test3"></span></p>
</body>
</html>