D
Don Li
No err msg but not working.
var tbl=document.getElementById('notesdetail');var
nrow=tbl.insertRow(0);var
c1=nrow.insertCell(0);c1.id='newdata';document.getElementById('newdata').value=document.getElementById('notes').value;
<form id="edit" style="display:none">
<textarea id="notes" name="notes" cols="50" rows="7">hot potato</
textarea><br/>
<input type="button" value="Add to top" onclick="//psueduo code, run
the above js">
</form>
<table id="notesdetail" style="display:none">
<tbody>
<!-- a new row should be inserted here --->
<tr>
<td valign="top"><b>abc</b></td>
<td>abc in detail</td>
</tr>
</tbody>
</table>
var tbl=document.getElementById('notesdetail');var
nrow=tbl.insertRow(0);var
c1=nrow.insertCell(0);c1.id='newdata';document.getElementById('newdata').value=document.getElementById('notes').value;
<form id="edit" style="display:none">
<textarea id="notes" name="notes" cols="50" rows="7">hot potato</
textarea><br/>
<input type="button" value="Add to top" onclick="//psueduo code, run
the above js">
</form>
<table id="notesdetail" style="display:none">
<tbody>
<!-- a new row should be inserted here --->
<tr>
<td valign="top"><b>abc</b></td>
<td>abc in detail</td>
</tr>
</tbody>
</table>