请教:表格一列里的对象如何取得 for(i=0;i<document.getElementById("tmp").cells.length;i++)alert(document.getElementById("tmp").cells[i].children[0].type) 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 <table> <tr id="ttt"> <td><input type="checkbox">s1</td> <td><input type="checkbox">s2</td> <td><input type="checkbox">s3</td> </tr> <tr id="tmp"> <td><input type="checkbox">s4</td> <td><input type="checkbox">s5</td> <td><input type="checkbox">s6</td> </tr></table><input onclick=a() type=button value="Test"><script>function a(){for(i=0;i<document.getElementById("tmp").cells.length;i++){alert(document.getElementById("tmp").cells[i].childNodes[0].type)alert(document.getElementById("tmp").cells[i].childNodes[1].nodeValue)}}</script> js截取字符串 页面解析json串 ie下ajax中文乱码问题 jquery 问题求教下了! 关于window.onload问题 web前端开发工程师 文本域中内容选中之后怎样实现取消选中 求助!怎样才能在本网页中单击后出现一个提示.就像右键单击的那种 如何判断一个日期时候合法? jquery 判断 $(document).on("ready", function () {}) 执行完成 我已经提前载入图片了,为什么还这么慢? 已提前载入图片,为何还这么慢?
<tr id="ttt">
<td><input type="checkbox">s1</td>
<td><input type="checkbox">s2</td>
<td><input type="checkbox">s3</td>
</tr>
<tr id="tmp">
<td><input type="checkbox">s4</td>
<td><input type="checkbox">s5</td>
<td><input type="checkbox">s6</td>
</tr>
</table>
<input onclick=a() type=button value="Test">
<script>
function a()
{
for(i=0;i<document.getElementById("tmp").cells.length;i++)
{
alert(document.getElementById("tmp").cells[i].childNodes[0].type)
alert(document.getElementById("tmp").cells[i].childNodes[1].nodeValue)
}
}
</script>