1

例如,我有一个 javascript 文件,其中包含不同的文本document.write();,例如:

document.write('here 1 line of text');

document.write('here 2 line of text');

我在我的 html 页面上添加了一个脚本文件:

<script type="text/javascript" src="jsfile.js"></script>

有没有办法从这个js文件加载一行文本而不是所有文本?例如,我只需要从 .js 文件中加载第一行 text 'here 1 line of text'

4

0 回答 0