PHP基础
PHP教程
php框架
JavaScript
asp.net
AJAX
正则表达式
ASP
输入
banner图
图片脚本
导航/分类
javascript连连看代码出炉_javascript技巧
输出表格 document.getElementById("timeleft").innerHTML = TmpTime;//显示剩余时间 document.getElementById("timebar").style.width = 600;//时间条 document.getElementById("timebar").style.backgroundColor = "green"; st = setInterval("ShowTime()",1000);//开始倒计时 } //X方向连线。(有起点,无终点) function LineX(x, y, xt){ for( i=x; i!=xt; (x
P2.y){ P3=P1; P1=P2; P2=P3; } //P1下方1点(y+1)先纵向再横向是否可连接。(因为起点P1不为空,所以检测其下方一点) if( LineY(P1.x, (P1.y+1), P2.y) && LineX(P1.x, P2.y, P2.x) ) return true; //P1先向左侧连接,再检测该点再纵向再横向是否可连接P2。 for(j=(P1.x-1); j>=0; j--){ if(Matrix[j][P1.y]) break; if( LineY(j, (P1.y+1), P2.y) && LineX(j, P2.y, P2.x) ) return true; } //P1先向右侧连接,再检测该点再纵向再横向是否可连接P2。 for(j=(P1.x+1); j
P2.x){ P3=P1; P1=P2; P2=P3; } if( LineX((P1.x+1), P1.y, P2.x) && LineY(P2.x, P1.y, P2.y) ) return true; for(j=(P1.y-1); j>=0; j--){ if(Matrix[P1.x][j]) break; if( LineX((P1.x+1), j, P2.x) && LineY(P2.x, j, P2.y) ) return true; } for(j=(P1.y+1); j
4 ){ document.getElementById("timebar").style.backgroundColor = "red"; } else if( (TimeMax/TmpTime)>2 ){ document.getElementById("timebar").style.backgroundColor = "yellow"; } if(!TmpTime){//剩余时间为0 clearInterval(st);//清除倒计时 document.getElementById("container").innerHTML = "";//清屏 document.getElementById("timeleft").innerHTML = ""; document.getElementById("timebar").style.backgroundColor = "white"; alert("时间到!"); } } //--> 行数
列数
图片数
时间
秒
重置
[Ctrl+A 全选 注:如需引入外部Js需刷新才能执行]