jQuery 获取遍历获取table中每一个tr中的第一个td的方法
如下所示:
<tbody id="already_question_list"> <tr> <td><?php echo $val['unique_number']; ?></td> <td><?php echo $val['year'].'-'.$val['series']; ?></td> <td><?php echo $val['content'] ?></td> <td><?php echo $val['knowledges'] ?></td> <td><?php echo $val['last_admin']; ?></td> <td> <input type="button" class="btn" value="-" data-score="<?php echo $val['score']; ?>" onclick='remove_selected(this);'/>\ <input type="hidden" name="question_numbers[]" value="<?php echo $val['unique_number']; ?>"/> </td> </tr> </tbody> <script> var leng = $("#already_question_list tr").length; var filter_numbs = new Array(); for(var i=0; i<=leng; i++) { numberStr = $("#already_question_list tr").eq(i).find("td:first").html(); filter_numbs.push(numberStr); } </script>
相关推荐
MXstudying 2020-09-05
WasteLand 2020-09-15
<?php. if (!empty($_POST)) {. $data1 = $_POST["data1"];$data2 = $_POST["data2"];$fuhao = $_POST["fuh
mathchao 2020-09-15
zyyjay 2020-11-09
xuebingnan 2020-11-05
samtrue 2020-11-22
stefan0 2020-11-22
yifangs 2020-10-13
songshijiazuaa 2020-09-24
hebiwtc 2020-09-18
天步 2020-09-17
83911535 2020-11-13
whatsyourname 2020-11-13
zhouyuqi 2020-11-10
Noneyes 2020-11-10
mathchao 2020-10-28
王志龙 2020-10-28