<script>
function click()
{
document.all('option').id='temp';
document.all('temp').innerText='文件';
document.all('file').id='option';
document.all('option').innerText='选项';
document.all('temp').id='file';
}
</script>

解决方案 »

  1.   

    <table border=1 id="tbl">
      <tr>
        <td id="option">选项</td>
        <td id="edit">编辑</td>
        <td id="file">文件</td>
      </tr>
    </table>
    <button onclick="chg1()">test1</button><script>
    function chg1()
    {
    if(tbl)
    {
    tbl.firstChild.firstChild.firstChild.swapNode(tbl.firstChild.firstChild.childNodes[1])
    }}</script>测试通过!
      

  2.   

    这里是给你一个提示,你可以结合 DHTML DOM 来简化 程序。上面用的是完全DOM 方法。
    tbl.firstChild.firstChild.firstChild 
    <==>
    tbl.rows(0).cells(0)Are you OK?
      

  3.   

    http://www.csdn.net/develop/Read_Article.asp?Id=8654
      

  4.   

    你们说的我都不懂,能不能说的详细写。javascript高层次的东西我还不太会,只能写简单的javascript脚本。
      

  5.   

    <table border=1 id="tbl">
      <tr>
        <td id="option">选项</td>
        <td id="edit">编辑</td>
        <td id="file">文件</td>
      </tr>
    </table>
    <button onclick="chg1()">test1</button><script>
    function chg1()
    {
    if(tbl)
    {tbl.rows(0).cells(0).swapNode(tbl.rows(0).cells(1))
    }}</script>我上面的程序你看了吗?
      

  6.   

    下载个表格控件,排序,拖动等功能的都有.
    http://fason.nease.net/zhuanti/table/sort.htm
    这个是我见过的最强的表格控件了,看看