怎么往input 加时间戳 求jq表达式

就是我想把 当前时间 写入input 然后我写的JQ把我的html给覆盖了 不知道怎么写 了 小白 自学

jquery获取时间戳用event的timeStamp方法获取。例如:显示出当对按钮元素的点击事件发生时的时间戳:htmlheadscript type="text/javascript" src="/jquery/jquery.js"/scriptscript type="text/javascript"$(document).ready(function(){ $("button").click(function(e){ $("span").text(e.timeStamp);});/script/headbody对下面这个按钮的点击事件发生在 1970 年 1 月 1 日之后 spanunknown/span 毫秒。buttonClick me/button/body/html运行结果:
温馨提示:答案为网友推荐,仅供参考
相似回答
大家正在搜