有没有办法直接在 html 文件中包含 prototype.js 代码? 我不想有这样的东西:
<script type="text/javascript" src="/path/to/prototype.js"></script>
我想要这样的东西:
<script type="text/javascript" >
// the code of prototype.js to be here
</script>
我想要的上下文更复杂。我现在只想知道这是否可能。 P.S.我对Prototype不是很熟悉。
谢谢。
最佳答案
是的,如果您将整个内容复制粘贴到脚本标签中,它就会起作用。
关于javascript - 直接在 html 文件中包含 prototype.js 代码,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/5866072/