Javascript 如何在 JSP 中包含 JS/CSS 文件(TOMCAT PROJECT)

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/14979939/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-24 18:33:56  来源:igfitidea点击:

How to Include a JS/CSS File in JSP (TOMCAT PROJECT)

javascriptcssjsp

提问by AHméd Net

i have an external javascript and css file and i want to incude it into my JSP file so im trying to test this code but is not working :

我有一个外部 javascript 和 css 文件,我想将它包含到我的 JSP 文件中,所以我尝试测试此代码但不起作用:

i don't want to use "include file='file.css'"

我不想使用“include file='file.css'”

<html>
   <head>
      <link href="css/bootstrap.min.css" rel="stylesheet"/>
      <script src="js/jquery-latest.js"></script>
      <script src="js/bootstrap.min.js"></script>
   </head>
   <body>
      <form class="form-horizontal well">
        login  : <input type="text">
        <br/>
        passw  : <input type="password">
        </form>
   </body>
</html>