页面里使用document,提示上下文中不存在。怎么处理啊!这种情况下怎么用document啊??

解决方案 »

  1.   

    document 在js里面用的    在js里面   用window.documentwindow可以点的出来。
    前台后台都可以用js!<script type="text/javascript">
     function getId(cs){
      var id=document.getElementById("txtId").value;
       alert(id); 
    </script>
      

  2.   

    JS的function 里
    document.getelementbyid()
      

  3.   

    嗯 我的代码又问提 没有用<script></script>引起来用document ,直接在页面的button里onclick="documnet"的 <input type="button" id="121" text="1321" onclick="document"/>
    所以就出不来!