write方法在浏览器显示不出
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.<html xmlns="http://www.
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>一个简单的JavaScript调试</title>
<script language="javascript">
function bar();
{
document.write("<hr>");
}
function output(headLevel,headText)
{
document.write("<H",headLevel,">",headText,">");
}
</script>
</head>
<body>
<script language="javascript">
bar();
output(1,"用JavaScript产生动态html");
{
document.write("<hr>");
}
</script>
</body>
</html>
书上写的答案是
————————————————————————————
用JavaScript产生动态html
————————————————————————————
可是预览后却什么也没显示(控件阻止的因素排除)
初学,望请大侠指点