writeln在结束的位置加了一个换行,但在页面中显示的只是一个空格,放在<pre></pre>里面才会进行换行

  document.write("<pre>第一行");
  document.writeln("第一行");
  document.writeln("这里是第二行");
  document.writeln("这里是第三行");
  document.writeln("这里是第四行</pre>");

相关文章: