如何利用javascript中函数清除document文档中所有内容 document.body.innerHTML = "" 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 阿弥陀佛<!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> <title>dhtml.document.clear.html</title> <meta name="generator" content="editplus" /> <meta name="author" content="Gao YiXiang" /> <meta name="email" content="[email protected]" /> <meta name="keywords" content="javascript dhtml dom" /> <meta name="description" content="I love web development." /></head><body> <h3>清除全部文档内容!注:IE6sp1, FF2 测试可用!</h3> <pre>clear MethodNot currently supported. To clear all elements in the current document, use document.write(""), followed by document.close.[/</pre> <input type="text" id="" /> <select id=""> <option value="" selected="selected"></option> <option value=""></option> </select> <input type="button" id="btnClear" value="Clear" /> <script type="text/javascript"> <!--document.clear = function(){ document.write(""); document.close();};document.getElementById("btnClear").onclick = function(){ document.clear();}; //--> </script></body></html>送你三本手册!DHTML参考手册http://download.csdn.net/source/308913样式表中文手册http://download.csdn.net/source/304124JScript语言参考http://download.csdn.net/source/308916 js 字符串TO array !!请问这是什么编码,怎么应用,立即给分 如何将一个表单的字符串更改后赋值到另一个表单 如何通过javascript将listbox中的项全部选中?? 如何判断用户下载完了 jsp中使用js实现多文件上传问题 如何动态控制层显示 动态增加表格(内有一组TEXT控件)后如何触发事件和动态计算? 主页面中怎样控制 IFrame中的网页中的元素及脚本 如何隐藏浏览器的地址栏、菜单栏、书签栏等浏览器组件 获取HTML元素的坐标 ActiveXobject对象 能在linux下创建吗?
<!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>
<title>dhtml.document.clear.html</title>
<meta name="generator" content="editplus" />
<meta name="author" content="Gao YiXiang" />
<meta name="email" content="[email protected]" />
<meta name="keywords" content="javascript dhtml dom" />
<meta name="description" content="I love web development." />
</head>
<body>
<h3>清除全部文档内容!注:IE6sp1, FF2 测试可用!</h3>
<pre>clear MethodNot currently supported. To clear all elements in the current document, use document.write(""), followed by document.close.[/</pre>
<input type="text" id="" />
<select id="">
<option value="" selected="selected"></option>
<option value=""></option>
</select>
<input type="button" id="btnClear" value="Clear" /> <script type="text/javascript">
<!--document.clear = function()
{
document.write("");
document.close();
};document.getElementById("btnClear").onclick = function()
{
document.clear();
};
//-->
</script>
</body>
</html>
送你三本手册!DHTML参考手册
http://download.csdn.net/source/308913样式表中文手册
http://download.csdn.net/source/304124JScript语言参考
http://download.csdn.net/source/308916