java程序,目的是:遍历Table中的Checkbox,如果被check了,则调用后台FileListServlet中的某个action
初步涉及,写了如下脚本,请问为什么一直报错:Uncaught ReferenceError: $ is not defined
$("#btnExecute").click(function(){ $("#tbFileList").find(":checkbox:checked").each(function(){ alert('a'); var tablerow = $(this).parent("tr"); var filename = tablerow.find("[name='fName']").val(); var filepath= tablerow.find("[name='fPath']").val(); var batpath="d:\\2.bat"; $.ajax({ type : "POST", contentType : "application/json", url : "FileListServlet?filename=" + filename + "&filepath=" + filepath + "&batpath=" + batpath + "&action=testcase" , dataType : 'json', }); }) });File Name | File Path | |
${filePro.fName} | ${filePro.fPath} |
<div>
<input type="button" id="btnExecute" value="Execute" ></div>