submit 提交表单后显示提交的时间
js文件里我的代码是functionSubmissionTime(){varSubmit=document.getElementById("submit");Submit...
js文件里我的代码是
function SubmissionTime ()
{
var Submit=document.getElementById("submit");
Submit.onclick=function ()
{
var Submission=new Date();
var Output="The time you submit the form is ";
document.write(Output);
document.write(Submission);
}
}
html里有 <script type="text/javascript" src="./JS/SubmissionTime.js"></script>
也定义了id <input type="button" name="submit" value="Submit" id="submit">,为什么无法实现想要的结果,初学js,不是很会,求帮忙!
在线等,跪求帮忙! 展开
function SubmissionTime ()
{
var Submit=document.getElementById("submit");
Submit.onclick=function ()
{
var Submission=new Date();
var Output="The time you submit the form is ";
document.write(Output);
document.write(Submission);
}
}
html里有 <script type="text/javascript" src="./JS/SubmissionTime.js"></script>
也定义了id <input type="button" name="submit" value="Submit" id="submit">,为什么无法实现想要的结果,初学js,不是很会,求帮忙!
在线等,跪求帮忙! 展开
1个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询