<table><tr><td onclick='a.value=this.innerText'>name</td><td onclick='b.value=this.innerText'>sex</td><td onclick='c.value=this.innerText'>birthday</td></tr></table>
<input name="a">
<input name="b">
<input name="c">
<input name="a">
<input name="b">
<input name="c">
<input name="a">
<input name="b">
<input name="c">
<script>
function aa(o)
{
a.value=o.cells(0).innerText
b.value=o.cells(1).innerText
c.value=o.cells(2).innerText
}
</script>
<tr><td>name1</td><td>sex1</td><td>birthday</td></tr>
<tr><td>name2</td><td>sex2</td><td>birthday</td></tr>
<tr><td>name3</td><td>sex3</td><td>birthday</td></tr>
</table>
<input name="a">
<input name="b">
<input name="c">
<script>
function aa()
{
o=event.srcElement
if(o.tagName=="TABLE" || o.tagName=="TBODY")
return
while(o.tagName!="TR")
{
o=o.parentElement
}
a.value=o.cells(0).innerText
b.value=o.cells(1).innerText
c.value=o.cells(2).innerText
}
</script>
<html>
<body>
<SCRIPT LANGUAGE="JavaScript">
<!--
function showinput()
{
elm = event.srcElement;
if (elm.tagName != "TD") return;
document.all.tablecell.value=elm.innerText;
}
//-->
</SCRIPT>
<TABLE border=1 height=100>
<thead id=thead1>
<tr>
<th></th>
<th width=100></th>
<th width=100></th>
<th width=100></th>
</tr>
<TR style="display:none">
<td><input type=checkbox id=checkLine></td>
<TD>000</TD>
<TD>000</TD>
<TD>000</TD>
</TR>
</thead>
<tbody onclick="showinput()" id=tbody1>
<TR>
<td><input type=checkbox id=checkLine></td>
<TD>aaa</TD>
<TD>bbb</TD>
<TD>ccc</TD>
</TR>
<TR>
<td><input type=checkbox id=checkLine></td>
<TD>ddd</TD>
<TD>eee</TD>
<TD>fff</TD>
</TR>
<TR>
<td><input type=checkbox id=checkLine></td>
<TD>ggg</TD>
<TD>hhh</TD>
<TD>iii</TD>
</TR>
</tbody>
<tfoot>
<tr>
<td colspan=4 align=center>
<input type="text" name="tablecell" size="20"></td>
</tr>
</tfoot>
</TABLE></body></html>