js实现延迟点击一个表单按钮的问题
怎样用javascript实现当我点击一个表单按钮后,必须等几秒后点击它才有效?能否举个例子?
<script>
function dd(){
var timedaye=setTimeout("alert('aa')",5000);
}
</script>
<input type="button" value="fafaf" onclick="dd()">
就这样
function dd(){
var timedaye=setTimeout("alert('aa')",5000);
}
</script>
<input type="button" value="fafaf" onclick="dd()">