编辑您的代码:
查看结果:
<html> <head> <script type="text/javascript"> function createCaption() { var x=document.getElementById('myTable').createTHead() x.innerHTML="我的表格标题" } </script> </head> <body> <table id="myTable" border="1"> <tr> <td>Row1 cell1</td> <td>Row1 cell2</td> </tr> <tr> <td>Row2 cell1</td> <td>Row2 cell2</td> </tr> </table> <br /> <input type="button" onclick="createCaption()" value="创建标题"> </body> </html>
查看结果:
系统帮助
|
给我留言
|
收藏本站
Copyright © 2005-2008
www.cnn84.com
All Rights Reserved Ver:2.0
CNN84网是公益性便民网站,是为了给大家的日常生活查询及提供最快捷的出行指南
中午好!还在浏览生活信息吗?CNN84提醒您别忘了午饭哦