<html>
<head>
<title></title>
<meta charset="UTF-8" />
<script type="text/javascript" src="jquery-1.8.3.min.js"></script>
<script type="text/javascript" src="Concurrent.Thread-full-20080319.js"></script>
<script type="text/javascript" src="game.js"></script>
<script type="text/javascript" src="test.js"></script>
<script type="text/javascript">
$(function(){
$('#button').click(function(event) {
var no = $('#no').val();
var orientation = $('#orientation').val();
var noReg = new RegExp("[^0-9]", "g");
var orientationReg = new RegExp("[^(,|0-9)]", "g");
if(no == "" || orientation == "" || noReg.test(no) || orientationReg.test(orientation)){
alert("输入不合法!");
return false;
}
orientation = orientation.replace(/,+$/g, "");
$('#node').append('<p>节点编号:<span name="no">' + $('#no').val() + '</span> 节点方向:<span>' + orientation + '</span><button id="delSingle" style="margin-left:5px;">删除</button><p>');
$('#no').val('');
$('#orientation').val('');
$('#no').focus();
});
$('#delSingle').live('click', function(event) {
$(this).parent().remove();
});
$('#delAll').live('click', function(event) {
$('#node').empty();
});
// $('#orientation').bind('keydown', function(event) {
// setTimeout("$('#orientation').val($('#orientation').val() + ',')", 300);
// });
});
</script>
<style type="text/css"></style>
</head>
<body align="center">
<div id="result" style="width:800px; margin-left:auto; margin-right:auto; margin-bottom:15px; min-height:20px;"></div>
<p style="margin:3px;">说明:节点为游戏中的点,节点方向为某节点所指向节点的编号,多个方向以逗号分开。<br/>
游戏开始前请按从上到下、从左到右为所有节点编号。
节点编号只能输入数字,节点方向只能输入数字、“,”。</p>
<div>
<span>节点编号:</span>
<input id="no" type="text" value="" style="width:30;">
<span>节点方向:</span>
<input id="orientation" type="text" value="">
<button id="button">添加节点</button>
</div>
<p style="margin-top:5px;"><button id="exec" >计算</button><button id="delAll" style="margin-left:5px">删除全部节点</button></p>
<div id="node"></div>
</body>
</html>

迹-
- 粉丝: 49
最新资源
- 网络安全(PPT36页)(1).ppt
- 论借助sniffer诊断Linux网络故障.docx
- 商务英语教学中网络的地位.doc
- 在市打击治理电信网络新型违法犯罪联席会议上表态发言三篇.doc
- 2023年大学计算机基础期末考试知识点.doc
- 系统安全预测技术.pptx
- 企业信息化建设的重要性和状况.docx
- 遥感数字图像处理考题整理.doc
- 高校师生同上一堂网络安全课观后感心得感悟5篇.docx
- 企业集团财务结算中心与计算机系统设计与会计操作.doc
- 电话网络系统方案.doc
- 九上下册物理第三节:广播-电视和移动通信公开课教案教学设计课件测试卷练习卷课时同步训练练习公开课教案.ppt
- 图像处理:十一表示描述.ppt
- 什么网站工作总结写的比较好.docx
- 项目管理与招标采购培训重点课程.doc
- 有关信息化银行对账问题的探讨【会计实务操作教程】.pptx
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈


