我遇到了這個JavaScript腳本的問題。我已經嘗試了許多事情來實現它。目前那裏的警報出於調試的目的,似乎沒有發生。調試JavaScript計時事件
請幫忙嗎?
function checkTime(this_time){
var the_string = "checkTime("+this_time+")";
var now = ((new Date()).getTime());
if(parseInt(now) >= parseInt(this_time)){
document.write("TIMEUP!");
}
alert(now);
alert(this_time);
var t = setTimeout(the_string,300);
}
var the_time = (((new Date()).getTime())+19000);
var the_string = "checkTime("+the_time+")";
var t = setTimeout(the_string,300);
感謝,
意志。
看到我的小提琴沒有外部變種:) – mplungjan 2011-05-02 13:11:11
@mplungjan:葉,看到它。另見http://jsfiddle.net/KooiInc/Bye2V/ – KooiInc 2011-05-02 13:36:39