<html>
<head><title>遍歷表格</title>
<script language="javascript">
function getData()
{
var arrData=new Array();
var objTable=document
if(objTable)
{
for(var i=
{
for(var j=
{
arrData[i]=objTable
}
}
}
alert(arrData
}
</script>
</head>
<body>
<table border="
<tr><td>liu</td><td>jin</td><td>cai</td></tr>
<tr><td>liu
<tr><td>liu
</table>
<form>
<input type="button" value="getData" onclick="getData();" />
</form>
</body>
</html>
From:http://tw.wingwit.com/Article/program/Java/JSP/201311/19811.html