问题:
   如题!     当单击某个按纽或图表时,生成一个新网页中,该网页不含有文本框!例:<html>
     <head>
       <table></table>
     </head>
     <body>
        <table id="powertable">
              <tr>
                <td>1<input type="hidden" name="cx" value="1"></td>
                <td>2<input type="hidden" name="cl" value="2"></td>
                <td>3<input type="hidden" name="cs" value="3"></td>
              </tr>
        </table>
     </body>
</html>
<input type="butten" name="sc" value="输出">点输出按纽输出一个新界面如下:<html>
     <head>
       <table></table>
     </head>
     <body>
        <table id="powertable">
              <tr>
                <td>1</td>
                <td>2</td>
                <td>3</td>
              </tr>
        </table>
     </body>
</html

解决方案 »

  1.   

    <body>
    <textarea id="kk" rows="10" cols="50"><html>
      <head>
      <table></table>
      </head>
      <body>
      <table id="powertable">
      <tr>
      <td>1<input type="hidden" name="cx" value="1"></td>
      <td>2<input type="hidden" name="cl" value="2"></td>
      <td>3<input type="hidden" name="cs" value="3"></td>
      </tr>
      </table>
      </body>
    </html></textarea>
    <input type="button" name="sc" value="输出" onclick="kk.value=kk.value.replace(/<input[^>]+>/gi,'')">
    </body>
      

  2.   

    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>文本</title>
    <script type="text/javascript">
    function print(){
    var data1=document.getElementById("cx").value;
    var data2=document.getElementById("cl").value;
    var data3=document.getElementById("cs").value;
    document.write(data1+" "+data2+" "+data3);

    }
    </script>
    </head>
      <body>
      <table id="powertable">
      <tr>
      <td><input type="hidden" id="cx" value="1"></td>
      <td><input type="hidden" id="cl" value="2"></td>
      <td><input type="hidden" id="cs" value="3"></td>
      </tr>
      </table>
      <input type="button" name="sc" value="输出" onclick="print();">
      </body>
    </html>
      

  3.   


    <script>var writePage=function(){
    var q=window.XMLHttpRequest?new XMLHttpRequest():new ActiveXObject("Microsoft.XMLHTTP");
    q.open("GET",location.href,false);q.send();
    document.write(q.responseText.replace(/<input[^>]*>/img,""));
    };
    </script>
    ...
    <input type="button" name="sc" value="输出" onclick="writePage()">
    ...