标签: jsp timer
如何在JSP页面中实现时间计数器,当点击开始它会倒计时,当时间弹出一条消息?
答案 0 :(得分:2)
您可以使用setTimeout javascript函数:
window.setTimeout(function() { // 5 seconds after the page is loaded show an alert: alert('5 seconds have passed since the page was loaded'); }, 5000);